✏️ 正在编辑: archive.php
路径:
/home/h359620/public_html/wp-content/themes/datis/template-parts/blog/archive/archive.php
提示:
您可以编辑任何文件(包括二进制文件),但请注意不当修改可能导致文件损坏。
<?php if (! defined('ABSPATH')) { exit; } $theme_options = get_option('datis_theme_options'); $blog_archive_top_template_id = ! empty($theme_options['blog_archive_elementor_template']) ? absint($theme_options['blog_archive_elementor_template']) : 0; $has_blog_archive_top_section = $blog_archive_top_template_id && class_exists('\Elementor\Plugin'); $blog_archive_card_style = ! empty($theme_options['blog_archive_card_style']) ? $theme_options['blog_archive_card_style'] : 'style-1'; $demo = get_option('datis_active_demo'); ?> <div class="container pt-3"> <?php if (function_exists('datis_breadcrumbs')) : ?> <div class="blog-breadcrumbs"> <?php datis_breadcrumbs(); ?> </div> <?php endif; ?> <?php if ($has_blog_archive_top_section) : ?> <div class="blog-archive-top-section mt-3 mt-lg-5"> <?php echo \Elementor\Plugin::$instance->frontend->get_builder_content_for_display( $blog_archive_top_template_id ); ?> </div> <?php endif; ?> <div class="d-flex flex-column gap-3 gap-lg-0 flex-lg-row m-0 mt-4"> <div class="col-12 col-lg-3 <?php echo $demo; ?>-demo m-0 p-0 p-0 ps-lg-3"> <?php get_template_part( 'template-parts/sidebar/sidebar', 'search', [ 'placeholder' => esc_html__('Search in blog…', 'datis'), 'field_name' => 'blog_search', ] ); ?> <div class="sidebar-filters-wrapper d-flex flex-column gap-3 p-4 mt-3"> <h3 class="sidebar-filters-title"><?php _e('Filters', 'datis'); ?></h3> <?php get_template_part('template-parts/sidebar/sidebar-order', 'filter'); get_template_part('template-parts/sidebar/sidebar-tax', 'filter'); ?> </div> </div> <div class="col-12 col-lg-9"> <?php if (have_posts()) : ?> <div class="datis-blog-loop d-flex flex-row justify-content-center justify-content-lg-start flex-wrap flex-lg-wrap gap-3"> <?php while (have_posts()) : the_post(); switch ($blog_archive_card_style) { case 'style-2': get_template_part('template-parts/blog/content/blog-content', '2'); break; case 'style-3': get_template_part('template-parts/blog/content/blog-content', '3'); break; case 'style-1': default: get_template_part('template-parts/blog/content/blog-content', '1'); break; } endwhile; ?> </div> <div class="datis-blog-pagination d-flex flex-row justify-content-center align-items-center mt-5"> <?php datis_pagination(); ?> </div> <?php else : ?> <div class="datis-blog-empty"> <?php get_template_part('template-parts/content', 'none'); ?> </div> <?php endif; ?> </div> </div> </div>
💾 保存文件
← 返回文件管理器