Show Only 1 Category in a Blog Page?

Discussion in 'GeoCraft WordPress Theme' started by suehope, Dec 16, 2012.

  1. suehope

    suehope New Member

    Joined:
    Dec 12, 2012
    Messages:
    19
    Likes Received:
    1
    Location:
    South Wales, UK
    Neeraj posted this in another thread:

    Thread located here:
    http://www.inkthemes.com/community/threads/posts-not-showing-in-menu.853/

    I wish to be able to do this as I have set up a blog on my Directory and only want blog posts to go there and NOT all of the listings, I have set up a category called GENERAL and I only want to show posts from that category, can you please show an example of the code you mention to modiy the blog page template to achieve this as you stated it could be done above.

    This is the link to my current blog page:
    http://www.carmarthenshirebiz.com/carms-blog/

    I am still in the stages of building this site :)

    Thanks for any help anyone can give :)

    Sue
     
  2. rogerb

    rogerb Active Member

    Joined:
    May 8, 2012
    Messages:
    481
    Likes Received:
    33
    Hi Sue,

    Is your blog page based on the blog template? If it is blogs should there automatically and not listings, I've done this on my test site and it seems to work OK - have a quick look.

    http://geocraft.myenglishbullterrier.com/aboutu/blog/

    Everything's a work in progress!

    Roger B
     
  3. suehope

    suehope New Member

    Joined:
    Dec 12, 2012
    Messages:
    19
    Likes Received:
    1
    Location:
    South Wales, UK
    Yes Roger, I have double checked many times, I made a page, called it Carms Blog, set it to have the themes blog template. I have then made a category "general" and posted to that category in the normal WP way. The blog page is pulling in the 1 Featured listing I so far have on the site and is not showing the post in General Category. The simple answer would seem to be, to have that page show only one category and that is the code/procedure I am asking for.

    Thanks for your help though :)

    Does anyone else have a suggestion?

    Sue
     
  4. rogerb

    rogerb Active Member

    Joined:
    May 8, 2012
    Messages:
    481
    Likes Received:
    33
    OK Sue, well another difference is that for my posts I have a specific post category called 'blog' rather than 'general' - I've done no other coding and have used the theme as is, posts and business listing seem to appear in the right places.

    Do you have any duplicated category names appearing in both your post and business listing categories? I'm not sure how easy it would be to change what actually appears in the post/blog without some help from a plug-in, this theme doesn't seem to be so easy to change!

    It also took me a little while to realise that you have to create a blog post as an admin in the admin area and that a normal user can't create a post, they can only add comments/reviews to an already existing one!

    Hope this helps
     
    suehope likes this.
  5. Neeraj

    Neeraj Administrator

    Joined:
    Jan 3, 2012
    Messages:
    186
    Likes Received:
    7
    Sue, This should help.

    aaa.png
     
    suehope likes this.
  6. suehope

    suehope New Member

    Joined:
    Dec 12, 2012
    Messages:
    19
    Likes Received:
    1
    Location:
    South Wales, UK
    Thanks Neeraj, hopefully that will do it, I will report back if there any issues.

    And thanks Roger for all your help too :)

    Sue
     
  7. rogerb

    rogerb Active Member

    Joined:
    May 8, 2012
    Messages:
    481
    Likes Received:
    33
    You are most welcome Sue but I'd be a little worried about why mine worked out of the box so to speak and you've had to do some manual coding. Next update you'll need to remember all these changes - I've changed the slider scroll speed etc so now I make a note of all these things for what looks like being many small updates!
     
  8. suehope

    suehope New Member

    Joined:
    Dec 12, 2012
    Messages:
    19
    Likes Received:
    1
    Location:
    South Wales, UK
    yep I know Roger, used to taking notes etc for client sites :) and I have not made too many changes. It is a mystery why yours worked and mine didn't but there you go lol oh and by the way, it shouldnt matter what one calls the category used nor the name of the page for a blog page. Thanks again, appreciated.

    Sue
     
  9. Neeraj

    Neeraj Administrator

    Joined:
    Jan 3, 2012
    Messages:
    186
    Likes Received:
    7
    Hi Sue,

    I think I misread your question, I thought you want to show the posts from only single category for which I gave you the solution above.

    However, It seems like you want to show normal blogposts excluding the Listings. Look through the image below to see what you need to do to add the regular blogposts.

    dd.png
     
  10. tonihogan

    tonihogan New Member

    Joined:
    Feb 22, 2013
    Messages:
    1
    Likes Received:
    0
    where to i find the code in the first post Neeraj
     
  11. Neeraj

    Neeraj Administrator

    Joined:
    Jan 3, 2012
    Messages:
    186
    Likes Received:
    7
    Under your theme folder, go to geocrafttheme>loop-blog.php file and open the file in notepad and than edit the file as shown.
     
  12. bill30075

    bill30075 New Member

    Joined:
    Dec 28, 2011
    Messages:
    7
    Likes Received:
    0
    Hello Neeraj:

    I'm trying to do the same thing - show only one category ("blog") on my blog page. I'm using the Colorway theme... any help would be appreciated!

    Thanks ;
    Bill
     
  13. Nitesh

    Nitesh Support Staff

    Joined:
    Oct 19, 2012
    Messages:
    5,165
    Likes Received:
    160


    Hello Bill,

    It is not possible to display post of single category on a blog page.
    There is one solution for it. Create a custom menu and add a particular category as a menu tab.
    Check image for reference.

    [​IMG]
     

Share This Page