Support » Themes and Templates » how to remove the 'read more'/'keep reading' button

  • Hi,
    I really want to get rid of the ‘keap reading’ button at the end of a post. I’ve tried anything, but nothing did it..

    After a lot of searching I found out I had to change the_excerpt into the_content. But couldn’t find where to in the index.php.
    Finally found something with the words excerpt and changed it into content. but nothing happened.

    someone please help me.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Michael

    (@alchymyth)

    Forum Moderator

    what theme are you working with?

    can you post a link to your site?

    I’m working with theme: Grisaille.

    My site uses a ‘under construction’ plugin. Because I don’t want to reveal to much yet. But if you really need it, I can deactivate it for so long.

    Michael

    (@alchymyth)

    Forum Moderator

    get rid of the ‘keap reading’ button at the end of a post

    just get rid of that button or also show the full post?

    to only remove the button, edit functions.php, and remove this:

    /**
    * Change excerpt [...] to something else
    **/
    
    function grisaille_new_excerpt_more($more) {
        global $post;
    	return ' ... <br /><a class="more-link" href="'. get_permalink($post->ID) . __('">keep reading</a>', 'grisaille');
    }
    add_filter('excerpt_more', 'grisaille_new_excerpt_more');

    to change the_excerpt() to the_content(), you will need to edit this line

    <?php the_excerpt(__('keep reading', 'grisaille')); ?></div>

    in these templates:

    home.php (for the front page posts)
    index.php
    archive.php (for archive pages)

    hey thanks man! it worked. Really glad about it! thanks!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘how to remove the 'read more'/'keep reading' button’ is closed to new replies.