- - -
- '; - echo '
'; - the_content(); - echo '
'; - } - } elseif ($one_cat > 0 && class_exists(DocumentNav::class)) { - $args = [ - 'cat' => $one_cat, - 'order' => 'DESC', - 'orderby' => 'modified', - 'posts_per_page' => 12, - 'no_found_rows' => true, - 'ignore_sticky_posts' => true, - 'post_status' => 'publish', - ]; - if ($initial === 'date_posts') { - $args['orderby'] = 'date'; - } elseif ($initial === 'views_posts') { - $args['orderby'] = 'meta_value_num'; - $args['meta_key'] = 'aksrt_post_views'; - } - $q = new WP_Query($args); - echo DocumentNav::render_posts_html($q); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped - } else { - echo '

' . esc_html__('请配置文档分类', 'aksrt') . '

'; - } - ?> -