add calendar events

This commit is contained in:
2021-10-31 13:01:31 +03:00
parent cbefa787b1
commit f97013cfaf
16 changed files with 701 additions and 52 deletions

View File

@@ -23,7 +23,7 @@ if( $posts ):
<div class="right_archive">
<a href="<?php the_permalink(); ?>"><img width="280" class="right_archive_img" src="<?php echo get_the_post_thumbnail_url($post, 'fil');?>" alt="<?the_title();?>"></a>
<div class="right_archive_text"><a href="<?php the_permalink(); ?>">Читать газету<br>«Ветеринария и Жизнь»</a></div>
<div class="right_archive_link"><a href="<?php the_permalink(); ?>">ежий номер</a></div>
<div class="right_archive_link"><a href="<?php the_permalink(); ?>"><?=the_title();?></a></div>
</div>

View File

@@ -1,4 +1,4 @@
<?php
<?php echo calend_block(date('m'), date('Y'), true);
# три последних эвента
@@ -6,12 +6,16 @@ $posts = get_posts( array(
'numberposts' => 3,
'category' => 61, // 61 - мероприятия
'orderby' => 'date',
'order' => 'DESC',
'include' => array(),
'exclude' => array(),
'meta_key' => '',
'meta_value' =>'',
'order' => 'ASC',
'date_query' => array(
array(
'after' => '3 days ago',
),
),
'post_type' => 'post',
'post_status' => 'publish, future',
'suppress_filters' => true, // подавление работы фильтров изменения SQL запроса
) );

View File

@@ -6,7 +6,7 @@
$mosts = get_posts( array(
'numberposts' => 3,
'category' => 2, // пока без категории
'post__in' => get_option( 'sticky_posts' ),
'orderby' => 'date',
'order' => 'DESC',
'include' => array(),