update theme
This commit is contained in:
@@ -1,8 +1,13 @@
|
||||
<?php
|
||||
get_header(); ?>
|
||||
<?
|
||||
$posts = get_post_query('post', 10,'ASC', '', get_queried_object()->slug);
|
||||
get_header();
|
||||
|
||||
$posts = new WP_Query([
|
||||
'category_name' => get_queried_object()->slug,
|
||||
'post_type' => 'post',
|
||||
'posts_per_page' => 10,
|
||||
'orderby' => 'date',
|
||||
'order' => 'ASC'
|
||||
]);
|
||||
?>
|
||||
<div class="content-middle articles-wrapper">
|
||||
<?php get_template_part('partials/rubrics-mobile'); ?>
|
||||
@@ -10,7 +15,7 @@ $posts = get_post_query('post', 10,'ASC', '', get_queried_object()->slug);
|
||||
<h1 class="section-title__title"><?= get_queried_object()->name ?></h1>
|
||||
</div>
|
||||
<div class="articles-preview">
|
||||
<? get_template_part('content-category-events-post', null, ['posts' => $posts, 'category'=> get_queried_object()->term_id])?>
|
||||
<? get_template_part('content-category-events-post', null, ['posts' => $posts, 'category' => get_queried_object()->term_id]) ?>
|
||||
</div>
|
||||
<?php custom_pagination($posts); ?>
|
||||
<a href="<?= home_url(); ?>" class="articles-preview__show-next">На главную</a>
|
||||
@@ -18,4 +23,4 @@ $posts = get_post_query('post', 10,'ASC', '', get_queried_object()->slug);
|
||||
|
||||
|
||||
<?php
|
||||
get_footer(); ?>
|
||||
get_footer(); ?>
|
||||
Reference in New Issue
Block a user