示例#1
0
<?php

global $ts_page_datas, $smof_data;
get_header($smof_data['ts_header_layout']);
$extra_class = "";
$page_column_class = ts_page_layout_columns_class($ts_page_datas['ts_page_layout']);
$show_breadcrumb = !is_home() && !is_front_page() && isset($ts_page_datas['ts_show_breadcrumb']) && absint($ts_page_datas['ts_show_breadcrumb']) == 1;
$show_page_title = !is_home() && !is_front_page() && absint($ts_page_datas['ts_show_page_title']) == 1;
if (function_exists('is_bbpress') && is_bbpress()) {
    $show_page_title = true;
    $show_breadcrumb = true;
}
if (($show_breadcrumb || $show_page_title) && isset($smof_data['ts_breadcrumb_layout'])) {
    $extra_class = 'show_breadcrumb_' . $smof_data['ts_breadcrumb_layout'];
}
ts_breadcrumbs_title($show_breadcrumb, $show_page_title, get_the_title());
?>
<!-- Page slider -->
<?php 
if ($ts_page_datas['ts_page_slider'] && $ts_page_datas['ts_page_slider_position'] == 'before_main_content') {
    ?>
<div class="top-slideshow">
	<div class="top-slideshow-wrapper">
		<?php 
    ts_show_page_slider();
    ?>
	</div>
</div>
<?php 
}
?>
 * The Template for displaying product archives, including the main shop page which is a post type archive.
 *
 * Override this template by copying it to yourtheme/woocommerce/archive-product.php
 *
 * @author 		WooThemes
 * @package 	WooCommerce/Templates
 * @version     2.0.0
 */
if (!defined('ABSPATH')) {
    exit;
}
// Exit if accessed directly
global $smof_data;
get_header($smof_data['ts_header_layout']);
$extra_class = "";
$page_column_class = ts_page_layout_columns_class($smof_data['ts_prod_cat_layout']);
$show_breadcrumb = get_post_meta(wc_get_page_id('shop'), 'ts_show_breadcrumb', true);
$show_page_title = apply_filters('woocommerce_show_page_title', true) && get_post_meta(wc_get_page_id('shop'), 'ts_show_page_title', true);
if ($show_breadcrumb && isset($smof_data['ts_breadcrumb_layout'])) {
    $extra_class = 'show_breadcrumb_' . $smof_data['ts_breadcrumb_layout'];
}
ts_breadcrumbs_title($show_breadcrumb, $show_page_title, woocommerce_page_title(false));
$show_top_content_widget_area = is_active_sidebar('product-category-top-content') && $smof_data['ts_prod_cat_top_content'];
?>
<div class="page-container <?php 
echo esc_attr($extra_class);
?>
">

	<!-- Left Sidebar -->
	<?php 
示例#3
0
<?php

global $smof_data;
get_header($smof_data['ts_header_layout']);
$page_column_class = ts_page_layout_columns_class($smof_data['ts_blog_layout']);
$show_breadcrumb = true;
$show_page_title = true;
$page_title = '';
$extra_class = "";
if ($show_breadcrumb && isset($smof_data['ts_breadcrumb_layout'])) {
    $extra_class = 'show_breadcrumb_' . $smof_data['ts_breadcrumb_layout'];
}
switch (true) {
    case is_day():
        $page_title = esc_html__('Day: ', 'gon') . get_the_date();
        break;
    case is_month():
        $page_title = esc_html__('Month: ', 'gon') . get_the_date(esc_html_x('F Y', 'monthly archives date format', 'gon'));
        break;
    case is_year():
        $page_title = esc_html__('Year: ', 'gon') . get_the_date(esc_html_x('Y', 'yearly archives date format', 'gon'));
        break;
    case is_search():
        $page_title = esc_html__('Search Results for: ', 'gon') . get_search_query();
        break;
    case is_tag():
        $page_title = esc_html__('Tag: ', 'gon') . single_tag_title('', false);
        break;
    case is_category():
        $page_title = esc_html__('Category: ', 'gon') . single_cat_title('', false);
        break;