correct mobile adv
This commit is contained in:
@@ -615,12 +615,14 @@ add_action( 'init', function () {
|
||||
|
||||
add_action( 'pre_get_posts', function ($query) {
|
||||
|
||||
if ( ! is_admin() && $query->is_main_query() ) {
|
||||
if ( ! is_admin() && $query->is_main_query() && is_category() ) {
|
||||
// не админка и основной цикл страницы
|
||||
|
||||
if ( is_category( 'arkhiv' ) ) {
|
||||
$query->set( 'posts_per_page', 9 );
|
||||
}
|
||||
$query->set( 'posts_per_page', 23 );
|
||||
//if ( is_category( 'arkhiv' ) ) {
|
||||
// $query->set( 'posts_per_page', 19 );
|
||||
// }
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user