Добрый вечер. У меня такая проблема. Создаю отдельную страницу и вывожу в нем Custom Post Type с сайдбаром и все четко отображается, так как надо. Но когда код этой же страницы вставляю в файл определенной таксономии Custom Post Type, то сайдбар у меня не отображается. В чем может быть проблема? Код страницы вставлю ниже.
<?php get_header(); ?>
<?php if( $cover = fxcatalog_get_cover_layout() ) : ?>
<?php get_template_part( 'template-parts/cover/layout-' . absint( $cover ) ); ?>
<?php endif; ?>
<?php get_template_part('template-parts/ads/below-header'); ?>
<div id="content" class="fxcatalog-site-content container websitecatalog">
<div style="padding-top: 0; background: #f9f9f9;" class="fxcatalog-module module-type-posts col <?php echo (!fxcatalog_has_combo_layout() && fxcatalog_get_archive_layout_type() == 'masonry') ? "fxcatalog-module-layout-" . fxcatalog_get_archive_layout_type() : '';?>">
<?php echo fxcatalog_get_archive_heading(); ?>
<div style="border: none; padding-top: 0;" id="catpostshome" class="paddingwithoutfirst">CATALOG FX</div>
<div class="row fxcatalog-posts">
<?php
$args = array(
'post_type' => 'website',
'publish' => true,
);
query_posts($args);
if ( have_posts() ) :
?>
<?php $grid = fxcatalog_get_archive_layout(); ?>
<?php $inject_ad_position = fxcatalog_get_archive_ad(); ?>
<?php
$i = 0;
$j = 0;
$base = 0;
$loop_position = 1;
while( have_posts() ) : the_post(); ?>
<?php echo fxcatalog_open_masonery_wrapper($j) ? '<div class="fxcatalog-masonry-wrapper">' : ''; ?>
<?php if( $i == count( $grid ) ) { $i = $base; } ?>
<?php if ( $inject_ad_position == $loop_position ) : ?>
<?php $post_col = $grid[$i]['col']; ?>
<div class="<?php echo esc_attr( fxcatalog_get_bootstrap_columns( $post_col )); ?> layout-<?php echo esc_attr(fxcatalog_get_archive_layout_type());?>">
<?php $post_col .= fxcatalog_get_archive_layout_type() === 'masonry' ? '-orig' : ''; ?>
<?php include( locate_template('template-parts/ads/archive.php') ); ?>
</div>
<?php $i++; ?>
<?php if( $i == count( $grid ) ) { $i = 0; } ?>
<?php endif; ?>
<?php $post_col = $grid[$i]['col']; ?>
<div class="<?php echo esc_attr( fxcatalog_get_bootstrap_columns( $post_col ) ); ?> layout-<?php echo esc_attr(fxcatalog_get_archive_layout_type());?>">
<?php $post_col .= fxcatalog_get_archive_layout_type() === 'masonry' ? '-orig' : ''; ?>
<?php include( locate_template('template-parts/layouts/customcontent-'. $grid[$i]['layout'].'.php') ); ?>
</div>
<?php if( isset( $grid[$i]['base'] ) ) { $base = $i; } ?>
<?php $i++; $j++; $loop_position++; ?>
<?php endwhile; ?>
<?php if ( $inject_ad_position == $loop_position && !empty( $grid[$i]['col'] ) ) : ?>
<?php $post_col = $grid[$i]['col']; ?>
<div class="<?php echo esc_attr( fxcatalog_get_bootstrap_columns( $post_col )); ?> layout-<?php echo esc_attr(fxcatalog_get_archive_layout_type());?>">
<?php $post_col .= fxcatalog_get_archive_layout_type() === 'masonry' ? '-orig' : ''; ?>
<?php include( locate_template('template-parts/ads/archive.php') ); ?>
</div>
<?php $i++; ?>
<?php if( $i == count( $grid ) ) { $i = 0; } ?>
<?php endif; ?>
<?php echo fxcatalog_close_masonery_wrapper() ? '</div>' : ''; ?>
<?php else: ?>
<?php get_template_part('template-parts/layouts/content-none'); ?>
<?php endif; ?>
</div>
</div>
<?php get_template_part( 'template-parts/pagination/'. fxcatalog_get_current_pagination() ); ?>
<?php $sidebar = fxcatalog_get_current_sidebar(); ?>
<?php if( $sidebar['position'] != 'none') : ?>
<div id="homepagesidebar" class="fxcatalog-sidebar allcatalogsidebar homepagesidebar col">
<?php if ( $sidebar['standard'] != 'none' && is_active_sidebar( $sidebar['standard'] ) ) : ?>
<?php dynamic_sidebar( $sidebar['standard'] ); ?>
<?php endif; ?>
</div>
<?php endif; ?>
</div>
<?php get_footer(); ?>