Ready to get started?Download WordPress


Categories as reviews (8 posts)

  1. mstess
    Posted 8 years ago #

    I just read the Urban Giraffe and am tweaking my first blog.
    I want to have several categories of reviews - Lodging, dining and activities. I changed the default category to Lodging, but my lodging post shows up on the main page.

    How can I change that?

    Also, I want sticky posts at the tops of each of these review categories. I am not sure where to add Get a Post. I downloaded Adhesive and that didn't work either.

    I am a newbie and this is an intense learning curve for me. Thanks for your help. I am sure that there is an easy solution, but I just don't see it.

    My incomplet website is http://www.travelbloggist.com


  2. tsguitar
    Posted 8 years ago #

    You don't want the category "Loding" to appear on your home page? What do you want to show on the home page?

    Find out the category number for "Loding" (Manage >> Categories). Let's pretend it's category 2. Here's how I have the beginning of my Loop written on my home page to exclude a certain category:
    <?php if (have_posts()) : query_posts($query_string .'&cat=-2'); while (have_posts()) : the_post();

    As for sticky posts at the tops of each review category, could you use the category description for this? Manage >> Categories >> Edit >> Description. Then you should be able to insert that category description on each category page. This should help:

  3. mstess
    Posted 8 years ago #

    Thanks. I will try this. I definitely don't want the Lodging Category as the category that loads up.

    Probably will be back with another question.

  4. tsguitar
    Posted 8 years ago #

    Please do and let me know if that method works to get "Lodging" off your home page.

  5. mstess
    Posted 8 years ago #


    I think that I created a bigger mess. I really do want a general travel blog on my home page. I did have that up, but it contained the posts that I wanted for the lodging category.
    I am getting ready to start over from scratch. I deleted all the categories from my page. Now I am back to square one.

    When I go to add categories nothing shows up on the home page, which I assume is because nothing has been posted. But, when I write a post and click to put it into a certain category, it doesn't go where I want it. It always seems to go to the home page category, but not the designated category.

    I will fool around with this some more. I assume that the above code would make things post just to the category with that number. Is that correct? I really appreciate any help. I am learning very slowly. I know that it will click at some point.


  6. mstess
    Posted 8 years ago #

    When I put in the code that you mentioned, I get the following error:

    Parse error: syntax error, unexpected '<' in

    I have removed the code. Is there something else that I should do?

  7. tsguitar
    Posted 8 years ago #

    The home page isn't a category. The home page just usually shows the latest blog entries, regardless of category. It just shows the most recent blog posts in the database.

    And I think you got that error because you put the code I suggested inside an already existing <?php tag. The code I suggested should replace the beginning of your Loop on your home page.

    Let me get this straight: what you want to appear on your home page are posts from all categories except the Lodging category? Do you want those posts to appear somewhere else? If all you're trying to do is exclude a single category from your home page, that code I gave you is the beginning for it and is exactly what I'm using to achieve the same result on my site (WP 2.0.4).

  8. mstess
    Posted 8 years ago #

    Thanks. I think that I figured it out. I did put the code at the front of the loop instead of replacing the beginning of the loop. I ended up finding a plug-in that worked well.
    Thanks for your help.

Topic Closed

This topic has been closed to new replies.

About this Topic