Pozdrav svima.
Trebam pomoć u vezi wp sajta, naime zelim na homepage da mi prikazuje samo postove iz određene kategorije ne zelim sve postove na homepage.
Tema je https://www.fabthemes.com/siren/
Hvala svima unaprijed
Kod homepage-a ide
<?php /** Template Name: Homepage * The main template file. * * This is the most generic template file in a WordPress theme * and one of the two required files for a theme (the other being style.css). * It is used to display a page when nothing more specific matches a query. * E.g., it puts together the home page when no home.php file exists. * Learn more: http://codex.wordpress.org/Template_Hierarchy * * @package web2feel * @since web2feel 1.0 */ get_header(); ?> <div id="article-area" class="cf ">
<div class="article-list ">
<?php
$count =ft_of_get_option('fabthemes_blog_number','3');
$args = array( 'numberposts' =>$count );
$lastposts = get_posts( $args );
foreach($lastposts as $post) : setup_postdata($post); ?>
<div class="grid-4">
<div class="article-box cf">
<?php
$thumb = get_post_thumbnail_id();
$img_url = wp_get_attachment_url( $thumb,'full' ); //get full URL to image (use "large" or "medium" if the images too big)
$image = aq_resize( $img_url, 480, 300, true ); //resize & crop the image
?>
<div class="homegallery">
<?php if($image) : ?> <a href="<?php the_permalink(); ?>"><img class="scale" src="<?php echo $image ?>"/></a> <?php endif; ?>
</div>
</div>
</div>
<?php endforeach; ?>
</div>
</div>
</div><!-- #primary .content-area -->
<header id="masthead" class="site-header container-12 role="banner">
<div class="top cf ">
<div id="botmenu" class="grid-8">
<?php wp_nav_menu( array( 'container_id' => 'submenu', 'theme_location' => 'primary','menu_id'=>'web2feel' ,'menu_class'=>'sfmenu','fallback_cb'=> 'fallbackmenu' ) ); ?>
</div>
</div>
</header>
<?php web2feel_content_nav( 'nav-below' ); ?>
<?php get_footer(); ?>