Forums

Loop help in dreamweaver! Only showing most recent post (1 post)

  1. fatjon0187
    Member
    Posted 10 months ago #

    Hey guys,

    I am in need of some assistance for my loop code. I am using Dreamweaver CS 5.5. Currently I have my blog at http://www.landbridgerecords.com/wordpress being fed to a website I am making which, for now, resides here: http://www.landbridgerecords.com/dreamweaver/JonandCateminus8TEST.php

    My problem is that only the most recent post appears to be showing up on the site as opposed to the three that are on the actual blog. I have checked my reading options and it is set 10. The only guess I have is there must be an error in my loop code, which I will post below. All I need to show up is the date, title and content of each post.

    <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
    
    <?php the_date('','<h2>','</h2>'); ?>
    
    <div class="post" id="post-<?php the_ID(); ?>">
    	 <h3 class="storytitle"><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h3>
    
    	<div class="storycontent">
    	  <?php the_content(__('(more...)')); ?>
    </div>
    
    </div>
    
    <?php endwhile; else: ?>
    <p><?php _e('Sorry, no posts matched your criteria.'); ?></p>
    <?php endif; ?>

    I also have this posted at the top of my code page so that it doesn't use the WP theme.

    <?php
    // Include WordPress
    define('WP_USE_THEMES', false);
    require('./wordpress/wp-load.php');
    query_posts('showposts=1');
    ?>

    Any help would be greatly appreciated as I have hit a dead end.

    Thank you! =)

    - Jon

Reply

You must log in to post.

About this Topic