• Hello, the problem I am having is with the following website: http://www.kerform.com. As you can see my homepage is not set to show all of my WordPress blog posts, but if you click on the “My Blog” link at the top then it takes you to my posts. Right now I just have that link set up to list all of the posts tagged with News. I really don’t like this because it doesn’t give me the comments link at the bottom of each posts and such. I was wondering if anyone knows of a better way to display all my blog posts when that link is clicked? Thanks.

Viewing 7 replies - 1 through 7 (of 7 total)
  • What you need to create is a loop.

    http://codex.wordpress.org/The_Loop

    Example:

    <?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?>
    // Do stuff here
    <h2><?php the_title(); ?></h2><br />
    <?php the_excerpt(); ?><br />
    
    <?php endwhile; else: ?>
    <p><?php _e('Sorry, no posts matched your criteria.'); ?></p>
    <?php endif; ?>

    Where do I create this loop? When I add it to a page, it doesn’t work. I want to create a page with all my posts as well. (I am a real code noob and I am Dutch, so that page is quite confussing.)

    Is that example the easiest code to have all your posts displayed on a page?

    Thread Starter Oztac

    (@oztac)

    Thank you! Exactly what I was looking for.

    Ok, I created the php file, uploaded it to the theme map I am using and at the page creator I selected the template, added a title and lest the rest of the stuff blank. However, my page remains blank as well…

    Any tips?
    http://rodneyleguit.nl/?page_id=108

    In this example the value of the Custom Field “category” is retrieved and used as the category to retrieve the posts in that category. So if the category of posts you want to display is called “Events” then assign the Custom Field “category” with a value of “Events” to the Page.

    Yeah, just found the solution. Thanks a lot!

Viewing 7 replies - 1 through 7 (of 7 total)

The topic ‘URL to display all wordpress posts’ is closed to new replies.