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

Wordpress category-pages

Discussion in 'Blogging' started by miansc, Jun 29, 2010.

  1. miansc

    miansc Regular Member

    Joined:
    Oct 1, 2009
    Messages:
    407
    Likes Received:
    126
    Location:
    Oz, maate
    Hey guys... Been trying to do this for days now. I'm trying to get my posts from my categories to show on my pages. I know this can be done, just having trouble finding out how to do it! I think you need to edit your theme, not sure.

    If anyone knows how to/plugin, please let me know :)

    Cheers.
     
  2. shylesson

    shylesson Power Member

    Joined:
    Jan 10, 2008
    Messages:
    665
    Likes Received:
    2,090
    Location:
    ‹^›‹(•¿•)›‹^›
    could ya clarify a bit more what you are looking for? You want to append posts to your pages?
     
  3. Bugalugs

    Bugalugs Regular Member

    Joined:
    Jan 27, 2007
    Messages:
    204
    Likes Received:
    381
    Yes I am interested in this as well but I would like to know how to get my categories to show all the posts in that category when I click on it.
    Is there a way?

    Bugs
     
  4. cnick79

    cnick79 Jr. VIP Jr. VIP

    Joined:
    Jun 10, 2010
    Messages:
    653
    Likes Received:
    341
    Location:
    Google's SandBox
    To Bugalugs:

    Are you using a theme or creating your own? WordPress makes use of the archives.php file to do this.

    Code:
    codex.wordpress.org/Creating_an_Archive_Index
     
    • Thanks Thanks x 1
    Last edited: Jun 29, 2010
  5. cnick79

    cnick79 Jr. VIP Jr. VIP

    Joined:
    Jun 10, 2010
    Messages:
    653
    Likes Received:
    341
    Location:
    Google's SandBox
    To the OP:

    Use the List Category Posts plugin. It will allow you to place posts for a specific category on any of your wordpress pages. All you need to do is put something like
    Code:
    [catlist=CATEGORYID]
    into your page and all posts under the CATEGORY ID will be displayed.

    Code:
    http:picandocodigo.net/programacion/wordpress/list-category-posts-wordpress-plugin-english/
     
    • Thanks Thanks x 1
  6. miansc

    miansc Regular Member

    Joined:
    Oct 1, 2009
    Messages:
    407
    Likes Received:
    126
    Location:
    Oz, maate
    exactly what i was looking for.. ill try soon.

    example of what I mean, www.dailytut.c0m look at his pages, he has linked his categories to them so that he can post on pages.. ( u know how pages are static )
     
  7. bodkin

    bodkin Newbie

    Joined:
    May 9, 2010
    Messages:
    5
    Likes Received:
    4
    You know on the dailytut blog I don't think he's done anything clever with putting categories on pages. He's just got menu items for the standard category pages on wordpress. Things like the blogging "page" aren't static pages, they're dynamically created category pages. No need for any plugins or anything - it's just what wordpress does when you click on a category link. All he's done (as is standard with many themes) is have menu items for the categories.

    BK
     
  8. cnick79

    cnick79 Jr. VIP Jr. VIP

    Joined:
    Jun 10, 2010
    Messages:
    653
    Likes Received:
    341
    Location:
    Google's SandBox
    I agree with bodkin, that site is using posts under the categories. Nothing special being done there.
     
  9. Bugalugs

    Bugalugs Regular Member

    Joined:
    Jan 27, 2007
    Messages:
    204
    Likes Received:
    381
    Thanks for answering.
    I use Brian Gardners Revolution Code and WP2.9 for this particlular blog. When I click on a category it just takes me to last post in that category and does not show all the posts in that category and for anyone to view all the posts they have to keep clicking on the posts to proceed. Its painful.
    How should archives.php be applied ?
    Thanks
    Bugalugs
     
  10. miansc

    miansc Regular Member

    Joined:
    Oct 1, 2009
    Messages:
    407
    Likes Received:
    126
    Location:
    Oz, maate
    Wow, no shit haha. Thanks man, I never thought of doing that ><

    Would this differ SEO in any way?
     
  11. miansc

    miansc Regular Member

    Joined:
    Oct 1, 2009
    Messages:
    407
    Likes Received:
    126
    Location:
    Oz, maate
    Also, i want to do what bugalugs said, so in fact im not actually making pages, but where the pages are it was have the link to the category
     
  12. radicalseo2

    radicalseo2 Newbie

    Joined:
    Jun 24, 2010
    Messages:
    49
    Likes Received:
    12
    This can be easily done with Wordpress, no need for plugins. All you need to do is to place the following line of code above the if have posts while have posts the post function.

    PHP:
    <?php query_posts($query_string '&nopaging=true'); ?>
    It should look similar to this

    PHP:
        <div class="main">
    <?php query_posts($query_string '&nopaging=true'); ?>
        <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
    Please note that the lines before and after can differ depending on the theme you are using.

    You can use the same code for tag pages as well.

    Update: Forgot to mention, this applies to category.php and tag.php. If you do not have those copy and rename the index.php file to have them.
     
    • Thanks Thanks x 1
    Last edited: Jun 30, 2010
  13. radicalseo2

    radicalseo2 Newbie

    Joined:
    Jun 24, 2010
    Messages:
    49
    Likes Received:
    12
    Oh, there is another option, which is especially useful if the blog has categories with hundreds of posts (the above code might thrown an out of memory error)

    PHP:
    <?php query_posts('showposts=100'); ?>
    Just add this line instead of the one above, this will limit the posts for the category / tag to 100. You can edit the number to one better suited for your situation.

    Update: Have to correct myself again. This only works properly if the category is specified as well, e.g.

    PHP:
    <?php query_posts('cat=41&showposts=100'); ?>
    This does mean however that you need to create category specific category pages, sounds complicated but is not.

    Lets say you have a category called SEO. All you need to do is to copy the category.php file and create a new file called category-seo.php.

    Wordpress looks first for category-seo.php. If it is found it displays its contents, if it is not found it resorts to category.php instead.
     
    • Thanks Thanks x 1
    Last edited: Jun 30, 2010
  14. miansc

    miansc Regular Member

    Joined:
    Oct 1, 2009
    Messages:
    407
    Likes Received:
    126
    Location:
    Oz, maate
    g stuff - helped heaps of ppl
     
  15. jeyamaria72

    jeyamaria72 Newbie

    Joined:
    Dec 9, 2009
    Messages:
    34
    Likes Received:
    13
    Hi
    I am doing the same on my blogs and my client blogs using two WP Plugins.
    1- AZIndex
    2- Post-Page-Associator

    Both of them works fine with the latest Wordpress 3.0.
    Some of my clients particularly request to have their pages with .html extension. What I do is, hide links to Category pages from Sidebar and Archive, Category, Index, Search, Single Post pages. Next, I use any one of those plugins to create pages with post from a particular Category or Categories. Even You can use Tags instead of Categories.
    I use " .html on Pages " plugin for the html extension.
     
    Last edited: Jul 7, 2010