PHP:
<?php
$args=array(
'posts_per_page' => 4,
'order'=> 'DESC',
'orderby'=> 'date',
'meta_value'=> 'on',
'post_type'=> 'post',
'ignore_sticky_posts '=> 1,
'post_status '=> 'publish'
);
$the_query = new WP_Query($args);
?>
<!-- BEGIN .panel -->
<div class="panel">
<div class="slider">
<div class="slider-image">
<?php $i=0;?>
<?php if ($the_query->have_posts()) : while ($the_query->have_posts()) : $the_query->the_post(); ?>
<a href="<?php the_permalink();?>"<?php if($i==0) { ?> class="active"<?php } ?>>
<span class="slider-overlay">
<strong><?php the_title();?></strong>
<span>
<?php
add_filter('excerpt_length', 'new_excerpt_length_10');
the_excerpt();
?>
</span>
</span>
a href="<?php the_permalink(); ?>"><?php the_post_thumbnail( 'dw-focus-slider' ); ?></a>
<?php $categories_list = get_the_category_list( __( ', ', 'dw-focus' ) );
if ( $show_category && $categories_list && dw_focus_categorized_blog() ) {
printf( '<span class="cat-links hidden-xs">' . __( '%1$s', 'dw-focus' ) . '</span>', $categories_list );
} ?>
<?php $i++; ?>
<?php endwhile;?>
<?php endif; ?>
</div>
<ul class="slider-navigation">
<?php $i=0;?>
<?php if ($the_query->have_posts()) : while ($the_query->have_posts()) : $the_query->the_post(); ?>
<li<?php if($i==0) { ?> class="active"<?php } ?>>
<a href="#" data-target="1">
<strong><?php the_title();?></strong>
<span>
<?php
add_filter('excerpt_length', 'new_excerpt_length_20');
the_excerpt();
?>
</span>
</a>
</li>
<?php $i++; ?>
<?php endwhile; else: ?>
<li><?php _e( 'No posts where found');?></li>
<?php endif; ?>
</ul>
</div>
<!-- END .panel -->
hazır bi manşet sisteminin kodunu düzenledim fakat kategorisini belirlediğim içeriği bu kodla gösteremiyorum.
konuyla ilgili yardımcı olabilir misiniz ? örn: cat=1 deki yazıları burada göstermek istiyorum