Support » Fixing WordPress » Read More functionality

  • I have a site where I use a ‘home’ page as the main landing page rather than the main blog page… I’m now trying to add a few recent posts on the home page template, and I’m having trouble with the Read More functioning correctly… The entire post is displayed rather than just the excerpt. Here’s the code I have in home-content.php:

    <?php query_posts('showposts=4&amp;cat=3'); ?>
      		<?php while (have_posts()) : the_post();?>
    			<div class="notebook-item <?php echo $odd_or_even; ?>">
    			<div class="post" id="post-<?php the_ID(); ?>">
    				<h2><small><span class="alignright date"><?php the_time('F jS, Y') ?></span></small><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2>
    
    					<?php the_content('read more...'); ?>
    
    			</div>
    			</div>
    			<?php $odd_or_even = ('odd'==$odd_or_even) ? 'even' : 'odd'; ?>
    			<?php endwhile; ?>

    Does anyone know how to get the Read More to function outside of the main blog (index.php) page? I know I could use ‘the_excerpt()’ but I don’t like how it ends with […].

    Thanks,
    Bryan

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Read More functionality’ is closed to new replies.