1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Wordpress custom categories in FrontPage

Discussion in 'Web Design' started by dragosdydy, Jun 12, 2013.

  1. dragosdydy

    dragosdydy Junior Member

    Joined:
    Jan 23, 2012
    Messages:
    116
    Likes Received:
    49
    Location:
    Italy
    Hello. I have a wordpress theme with a custom Front Page already created by the theme with a little Slider and then articles.
    Because is only a simple custom front page without options in the Theme Menu, i can't select what posts are shown in the Slider.
    I just want to show articles from a specific category in that Slider, because now are the latest articles.
    I tried to find a workaround with the following code but didn't succeed:
    Code:
    <?php
    query_posts('cat=4');
    ?>
    
    and also with that
    Code:
    <?php query_posts('category_name=CategoryName'); ?>
    
    But still didn't managed to make a change.

    The custom home page code is: http://pastebin.com/MMZFNKVy
    The website where you can see an example of the theme is : http://leadrights.com

    Thanks a lot guys.
     
  2. Conor

    Conor Jr. VIP Jr. VIP

    Joined:
    Nov 7, 2012
    Messages:
    3,358
    Likes Received:
    5,420
    Gender:
    Male
    Location:
    South Africa
    Home Page:
  3. dragosdydy

    dragosdydy Junior Member

    Joined:
    Jan 23, 2012
    Messages:
    116
    Likes Received:
    49
    Location:
    Italy
    Hi, thanks for your suggestion but i need to keep the theme with its original slider. I need to modify the actual code of the custom homepage. Thanks.
    //Later edit:
    Resolved it after trying more things from here http://codex.wordpress.org/Class_Reference/WP_Query . Thanks.
     
    Last edited: Jun 13, 2013