Title: Having &#8220;continue&#8221; only appear when needed&#8230;
Last modified: August 19, 2016

---

# Having “continue” only appear when needed…

 *  Resolved [nickaster](https://wordpress.org/support/users/nickaster/)
 * (@nickaster)
 * [16 years ago](https://wordpress.org/support/topic/having-continue-only-appear-when-needed/)
 * Hi – by default on my front page, I get a “this post continues” link, which makes
   sense because 99% of the time the post is longer and continues on the permalink
   page.
 * If I make a short post, the continue button is stil there. I’d like it to NOT
   be there unless needed. How do I do this? Here’s the code I have on my front 
   page:
 * `<a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?
   php the_title_attribute(); ?>"> CONTINUES &raquo;</a>`
 * As you can see, there’s no if/then thing in there about weather the most is using
   the “more” feature.
 * How do I change this?
 * Thanks!

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

 *  [esmi](https://wordpress.org/support/users/esmi/)
 * (@esmi)
 * [16 years ago](https://wordpress.org/support/topic/having-continue-only-appear-when-needed/#post-1500940)
 * Assuming you’re using a combination of the_content and the <!–more–> tag, you
   could try testing for the presence of the <!–more–> tag and only generate a more
   link if the more tag has been used>
 *     ```
       <?php the_content('');;?>
       <?php if( strpos($post->post_content, '<!--more-->') ) :?><a class="more-link" href="<?php the_permalink();?>"><?php _e('this post continues');?> <?php the_title();?></a><?php endif;?>
       ```
   
 *  Thread Starter [nickaster](https://wordpress.org/support/users/nickaster/)
 * (@nickaster)
 * [16 years ago](https://wordpress.org/support/topic/having-continue-only-appear-when-needed/#post-1500988)
 * esmi, thanks a million. Yeah, I’m using <!–more–> … your suggestion did something
   really weird – it printed out the first section of every post 2x and ignored 
   the second part alltogether…
 * Any idea what went wrong? Thanks!
 *  Thread Starter [nickaster](https://wordpress.org/support/users/nickaster/)
 * (@nickaster)
 * [15 years, 12 months ago](https://wordpress.org/support/topic/having-continue-only-appear-when-needed/#post-1501021)
 * Got any other ideas for how this might work? I know it was standard back in the
   movable type days…would this require a plugin?
 *  [Michael](https://wordpress.org/support/users/alchymyth/)
 * (@alchymyth)
 * [15 years, 12 months ago](https://wordpress.org/support/topic/having-continue-only-appear-when-needed/#post-1501022)
 * > it printed out the first section of every post 2x and ignored the second part
   > alltogether…
 * difficult to tell without getting the whole picture.
 * could you paste the whole index.php (assuming that this is what you are working
   on) in a [http://wordpress.pastebin.com/](http://wordpress.pastebin.com/) and
   post the link to it here?
    a link to your site might further help to illustrate
   your ‘problem’
 *  Thread Starter [nickaster](https://wordpress.org/support/users/nickaster/)
 * (@nickaster)
 * [15 years, 12 months ago](https://wordpress.org/support/topic/having-continue-only-appear-when-needed/#post-1501035)
 * Right on, thanks! Here it is:
 * [http://wordpress.pastebin.com/WwxkRWnX](http://wordpress.pastebin.com/WwxkRWnX)
 *  [Michael](https://wordpress.org/support/users/alchymyth/)
 * (@alchymyth)
 * [15 years, 12 months ago](https://wordpress.org/support/topic/having-continue-only-appear-when-needed/#post-1501039)
 * pastebin link is either expired or unknown 🙁
 *  Thread Starter [nickaster](https://wordpress.org/support/users/nickaster/)
 * (@nickaster)
 * [15 years, 12 months ago](https://wordpress.org/support/topic/having-continue-only-appear-when-needed/#post-1501045)
 * hmm… that’s weird. I just tested it in a couple browsers and on someone else’s
   machine… they say it worked.
 *  Thread Starter [nickaster](https://wordpress.org/support/users/nickaster/)
 * (@nickaster)
 * [15 years, 12 months ago](https://wordpress.org/support/topic/having-continue-only-appear-when-needed/#post-1501058)
 * That paste bin still failing?
 *  [Michael](https://wordpress.org/support/users/alchymyth/)
 * (@alchymyth)
 * [15 years, 12 months ago](https://wordpress.org/support/topic/having-continue-only-appear-when-needed/#post-1501060)
 * pastebin must have been in maintenance;
    as far as i can interprete your code,
   this should be what [@esmi](https://wordpress.org/support/users/esmi/) suggested,
   integrated into place:
 *     ```
       <div class="entry">
                 <?php the_content('',FALSE,''); ?>
   
                 <p class="more"><img src="<?php bloginfo('template_url');?>/images/page_white_text.png"  alt="Permalink" />
       <?php if( strpos($post->post_content, '<!--more-->') ) :?>
       <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"> CONTINUES &raquo;</a>
       <?php endif;?>
       <img src="<?php bloginfo('template_url');?>/images/usergroup2-vi.gif" /> <a href="<?php the_permalink() ?>">Discuss This &raquo;</a></p>
       </div>
       ```
   
 * unless some plugin interferes with it, i can’t see any reason why this would 
   not work.
 *  Thread Starter [nickaster](https://wordpress.org/support/users/nickaster/)
 * (@nickaster)
 * [15 years, 12 months ago](https://wordpress.org/support/topic/having-continue-only-appear-when-needed/#post-1501067)
 * Phenomenal! IT worked! Thank You!!!

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

The topic ‘Having “continue” only appear when needed…’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 10 replies
 * 3 participants
 * Last reply from: [nickaster](https://wordpress.org/support/users/nickaster/)
 * Last activity: [15 years, 12 months ago](https://wordpress.org/support/topic/having-continue-only-appear-when-needed/#post-1501067)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
