Remove the ‘READ MORE’ button
-
Hi guys.
I tried a search, but did not find any topics about this, so here goes:
I’ve just uloaded and installed the newest WordPress. I’ve written a story and some pages – but the story on the main page is just a few lines long, and with a “READ MORE” button. Any way to remove this, and publish the whole story on the main page?
Screenshot:
https://bildr.no/view/360592Thanks in advance for all answers ??
-
Hello christer.trasti,
Your read more button is located inside your theme. Look inside the index.php file, you should see it.
If you have any questions, let me know ??
@ motivatingfactor:
Hey! Thank you for your swift reply.I’m very new to PHP code, and frankly, it scares me ??
Here is my index.php. I’ve tried everything to remove it, but have so far failed horribly. Can you see it?
Thanks again!! ??
<?php get_header(); ?> <div id="content" class="narrowcolumn"> <?php if (have_posts()) : ?> <?php while (have_posts()) : the_post(); ?> <div class="post" id="post-<?php the_ID(); ?>"> <div class="postwrapper"> <a href="<?php the_permalink() ?>" rel="bookmark" title="Continue reading the rest of this entry »"><img src="<?php $key="thumbnail"; echo get_post_meta($post->ID, $key, true); ?>" alt="thumbnail" class="thumbnail" /></a> <h2><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2> <div class="entry"> <?php the_excerpt(); ?> </div> </div> <div class="postmetadata"> <span class="thetime"><?php the_time('F jS, Y') ?></span> <span class="thecategory"><?php the_category(', ') ?></span> <?php edit_post_link('Edit', '<span class="editthispost">', '</span>'); ?> <span class="thecomments"><?php comments_popup_link('No Comments »', '1 Comment »', '% Comments »'); ?></span> <div class="readmore"> <a href="<?php the_permalink() ?>" rel="bookmark" title="Continue reading the rest of this entry »">Read More</a> </div> </div> </div> <?php endwhile; ?> <div class="navigation"> <div class="navleft"><?php next_posts_link('Older Entries') ?></div> <div class="navright"><?php previous_posts_link('Newer Entries') ?></div> </div> <?php else : ?> <h2 class="center">Not Found</h2> <p class="center">Sorry, but you are looking for something that isn't here.</p> <?php include (TEMPLATEPATH . "/searchform.php"); ?> <?php endif; ?> </div> <?php get_sidebar(); ?> <?php get_footer(); ?>
Here is your revised code:
<?php get_header(); ?>
<div id=”content” class=”narrowcolumn”>
<?php if (have_posts()) : ?>
<?php while (have_posts()) : the_post(); ?>
<div class=”post” id=”post-<?php the_ID(); ?>”>
<div class=”postwrapper”>
” rel=”bookmark” title=”Continue reading the rest of this entry ?”><img src=”<?php $key=”thumbnail”; echo get_post_meta($post->ID, $key, true); ?>” alt=”thumbnail” class=”thumbnail” />
<h2>” rel=”bookmark” title=”Permanent Link to <?php the_title_attribute(); ?>”><?php the_title(); ?></h2>
<div class=”entry”>
<?php the_excerpt(); ?>
</div>
</div>
<div class=”postmetadata”>
<span class=”thetime”><?php the_time(‘F jS, Y’) ?></span>
<span class=”thecategory”><?php the_category(‘, ‘) ?></span>
<?php edit_post_link(‘Edit’, ‘<span class=”editthispost”>’, ‘</span>’); ?>
<span class=”thecomments”><?php comments_popup_link(‘No Comments ?’, ‘1 Comment ?’, ‘% Comments ?’); ?></span><!–Below I have removed the Read More–>
<?php /*?> <div class=”readmore”>
” rel=”bookmark” title=”Continue reading the rest of this entry ?”>Read More
</div>
<?php */?><!–Above I have removed the Read More–>
</div>
</div><?php endwhile; ?>
<div class=”navigation”>
<div class=”navleft”><?php next_posts_link(‘Older Entries’) ?></div>
<div class=”navright”><?php previous_posts_link(‘Newer Entries’) ?></div>
</div><?php else : ?>
<h2 class=”center”>Not Found</h2>
<p class=”center”>Sorry, but you are looking for something that isn’t here.</p>
<?php include (TEMPLATEPATH . “/searchform.php”); ?><?php endif; ?>
</div>
<?php get_sidebar(); ?>
<?php get_footer(); ?>@ christer.trasti –
Please note to remove the commented code:
<!--Below I have removed the Read More--> <?php /*?> <div class="readmore"> " rel="bookmark" title="Continue reading the rest of this entry ?">Read More </div> <?php */?> <!--Above I have removed the Read More-->
Hi again motivatingfactor;
thanks again for your quick reply.
I tried what you mentioned above;
And now this happens:Link to screenshot:
https://bildr.no/view/360635The button has disappeared, but the whole story is still not present on the first page. And it looks as if something is wrong. I’ve tried what you said two times, just to be sure I didn’t do anything wrong.
Sorry to be such a hassle – and thanks for the great help!
Any more tips? ??
Best regards,
Christer@christer.trasti –
Here you are, use this code:
<?php get_header(); ?> <div id="content" class="narrowcolumn"> <?php if (have_posts()) : ?> <?php while (have_posts()) : the_post(); ?> <div class="post" id="post-<?php the_ID(); ?>"> <div class="postwrapper"> <a href="<?php the_permalink() ?>" rel="bookmark" title="Continue reading the rest of this entry ?"><img src="<?php $key="thumbnail"; echo get_post_meta($post->ID, $key, true); ?>" alt="thumbnail" class="thumbnail" /></a> <h2><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2> <div class="entry"> <?php the_content(); ?> </div> </div> <div class="postmetadata"> <span class="thetime"><?php the_time('F jS, Y') ?></span> <span class="thecategory"><?php the_category(', ') ?></span> <?php edit_post_link('Edit', '<span class="editthispost">', '</span>'); ?> <span class="thecomments"><?php comments_popup_link('No Comments ?', '1 Comment ?', '% Comments ?'); ?></span> <div class="readmore"> <!-- <a href="<?php the_permalink() ?>" rel="bookmark" title="Continue reading the rest of this entry ?">Read More</a>--> </div> </div> </div> <?php endwhile; ?> <div class="navigation"> <div class="navleft"><?php next_posts_link('Older Entries') ?></div> <div class="navright"><?php previous_posts_link('Newer Entries') ?></div> </div> <?php else : ?> <h2 class="center">Not Found</h2> <p class="center">Sorry, but you are looking for something that isn't here.</p> <?php include (TEMPLATEPATH . "/searchform.php"); ?> <?php endif; ?> </div> <?php get_sidebar(); ?> <?php get_footer(); ?>
If you have any more issues, So I can help you quickly, can you please begin a chat with me on one of the following:
skype: motivatebusiness
yahoo: motivatebusinessThis way I can quickly address any issues.
- The topic ‘Remove the ‘READ MORE’ button’ is closed to new replies.