• I want my blog page to only show the featured image with a “more” button after the image. I’ve succeeded in that, but I want to change the “Continue Reading” text with something like “View More Photos” or something like that.

    The page I need help with: [log in to see the link]

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter dannydanny

    (@dannydanny)

    I’d like to find a way to do this globally, but I’ve found a way to do it per post.

    In the code editor, change the more tag to something like this:

    <!-- wp:more -->
    <!--more View More Photos!-->
    <!-- /wp:more -->

    And it works fine.

    But I’d like to be able to do this globally for the site so that would be nice to find an answer to that.

    You would need to activate the Code Snippets ( https://ww.wp.xz.cn/plugins/code-snippets/ ) plugin on your site. Then create a new snippet and use the following code in the textarea of the code snippet

    function modify_read_more_link() {
        return '<a class="more-link" href="' . get_permalink() . '">View More Photos!</a>';
    }
    add_filter( 'the_content_more_link', 'modify_read_more_link' );
Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Change “Continue Reading” Text for Excerpt’ is closed to new replies.