Support » Themes and Templates » <!–more–> tag ignored

  • Hey there,

    On my site, I have a page which displays every first post of four different categories. I did this with the get_post script I found here.

    <?php $lastposts = get_posts('numberposts=1&category=3');
            foreach($lastposts as $post) :
    	  <h2 class="first_column_head1"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"><?php the_title(); ?></a></h2>
    	  <div class="post_content">
    	    <?php the_content(__('Read more...')); ?>
          <?php endforeach; ?>

    Now I read on this page, that the <!–more–> tag doesn’t work if there’s only one post. Is there some way I can hack this?


Viewing 2 replies - 1 through 2 (of 2 total)
  • I think you just need to change the_content to the_excerpt.

    Hmm.. Yes I tried that, but it doesn’t work, probably because I have only an image before the <!--more-->tag. And the exerpt doesn’t work with html tags I think…

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘<!–more–> tag ignored’ is closed to new replies.