Support » Fixing WordPress » How do you Remove a Read More Button?

  • Hello guy’s, well here is my dilemma, on my blog page i am trying to remove the “Read More” button that comes on standard no matter how long the post with the downloaded theme that i am creating my website around.

    Here is my index.php

    <?php get_header(); ?>
    		<!-- Content -->
    		<section id="content">
    			<?php if( have_posts() ): ?>
    				<?php /* Start the Loop */ ?>
    				<?php while ( have_posts() ) : the_post(); ?>
    					<?php get_template_part( 'content', get_post_format() ); ?>
    				<?php endwhile; ?>
    			<?php endif ?>
    			<!-- Pagination -->
    			<?php next_pagination(); ?>
    			<!-- End Pagination -->
    			<div id="top">
            		<a href="#top" title="Back To Top">Top ↑</a>
    		<!-- End Content -->
    <?php get_footer(); ?>

    [Please use the code buttons when posting code here]

Viewing 7 replies - 1 through 7 (of 7 total)
  • <?php get_template_part( 'content', get_post_format() ); ?>

    this part loads your content.php or content-{post_format}.php file and displays the post content and associated links, so you need to look into these files in order to remove the read more link.

    Oh really? thank you very much for your reply man!

    i opened my content php. any clues here?

     * The default template for displaying content
     * @package WordPress
     * @subpackage Just Blog
     * @since Just Blog 1.0
    <!-- Standard Post -->
    <article id="post-<?php the_ID(); ?>" <?php post_class('post'); ?>>
    	<div class="post-header">
    		<h3 class="post-title"><a>" title="<?php printf( esc_attr__( 'Permalink to %s', TEXTDOMAIN ), the_title_attribute( 'echo=0' ) ); ?>"><?php the_title(); ?></a></h3>
    		<div class="post-meta">
    				<?php $tags_list = get_the_tag_list( '', __( ', ', TEXTDOMAIN ) );  ?>
    				<li class="post-date"><?php the_time(get_option('date_format')); ?>
    				<li class="post-comment"><a>"><?php comments_number('No Comments', '1 Comment', '% Comments'); ?></a>
    				<li class="post-author"><?php printf('<a href="%2$s">By %1$s</a>', get_the_author(), get_author_posts_url(get_the_author_meta( 'ID' ))); ?>
    				<li class="post-tag"><?php printf( __( '%2$s', TEXTDOMAIN ), '', $tags_list ); ?>
    	<div class="post-content">
    		<?php the_content(); ?>
    		<div class="read-more-container">
    			<a>" class="read-more"><?php _e('Read More', TEXTDOMAIN); ?></a>
    <!-- End Standard Post -->

    [Again, you need to use the code buttons – please read this: ]

    <div class="read-more-container">
    			<a>" class="read-more"><?php _e('Read More', TEXTDOMAIN); ?></a>

    how about this bit?

    Ha yeah that looks like you hit it on the head man! so the only question left is how do i remove it? i tried removing the code but it does absolutely nothing to the page, sigh

    A link would be nice. You first need to make sure that you edit the right file. The file for single post preview, category preview, default etc will be different. Add something to it to make sure you’re editing the right one, check other files too.
    Here is the template hierarchy that may be helpful.

    Thanks a lot man! here is the website for you i am creating for an artist “here and i am really trying to understand where you are coming from with “make sure you edit the right file” but i am about to check out the Hierarchy right now as we speak

    Okay so i figured out how to remove the “Read More” button from opening Content-image.php and removing the same exact code. but my ultimate goal of achieving that was to be able to put the Twitter/FB share buttons on the bottom of every picture i thought the Read More button was an issue because you can only share a picture when you click the blog post and it takes you inside. I’m trying to make it appear outside of every blog post how would i accomplish that? btw i tried the options on the plugins to make it appear outside but it fails to work. I think theres a mask/filter blocking it but i’m to unsure

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘How do you Remove a Read More Button?’ is closed to new replies.