У меня проблема с отображением страницы моей категории в результатах разбиения на страницы
У меня есть пользовательский тип сообщений под названием «видео».
Я помещаю все посты этого типа в одну категорию с названием «автомобили видео».
Я использую страницу шаблона category-9.php, поскольку идентификатор этой категории «автомобили» равен «9».
Я помещаю этот код в категорию-9.php
<?php
$paged = (get_query_var('paged')) ? get_query_var('paged') : 1;
?>
<?php query_posts( $query_string . '&post_type=videos&posts_per_page=10&paged=' . $paged ); ?>
<?php if ( have_posts() ) : ?>
<?php
/* Start the Loop */
while ( have_posts() ) : the_post();
/* Include the post format-specific template for the content. If you want to
* this in a child theme then include a file called called content-___.php
* (where ___ is the post format) and that will be used instead.
*/
get_template_part( 'content', 'videos' );
endwhile;
// twentytwelve_content_nav( 'nav-below' );
?>
<?php paging(); ?>
<?php else : ?>
<?php get_template_part( 'content', 'none' ); ?>
<?php endif; ?>
У меня первая страница sitename.com/blog/category/cat-videos/ работает нормально, но эта страница не работает
'sitename.com/blog/category/cat-videos/page/1'
'sitename.com/blog/category/cat-videos/page/2'
так далее..
это дало мне страницу 404.php
Это пользовательская регистрация поста
$post_type_args = array(
'label' => 'Videos',
'labels' => array(
'name' => 'Videos',
'singular_name' => 'Video',
'menu_name' => 'Videos'
),
'public' => true,
'has_archive' => true,
'hierarchical' => true,
'supports' => array('title','author','thumbnail','comments'),
'rewrite' => array('slug' => 'videos'),
'taxonomies' => array('category','post_tag')
);
register_post_type('videos',$post_type_args);
Любые советы?