What code in the WP Sinatra theme generates the words “Read More?”

I’m pulling my hair out. I have searched and searched for a way to remove the “Read More” link from my posts (full post, not excerpt). I’ve tried to add the filter below (and other pieces of code in functions.php) promoted in a number of places on the web. The filter works to turn the excerpt into a full-content post, but the same filter is also supposed to set the Read More text to null. Here’s what I’m using.

/**
 * Redefine sinatra_excerpt function.
 * 
 */
function sinatra_excerpt( $length = null, $more = null ) {
    the_content();
}

This function partially works in that it results in showing the full post rather than just an excerpt. it’s just the $more part that doesn’t work.

For what it’s worth, I have also tried various CSS examples until I’m blue in the face, most utilizing “display:none” on various elements.

I have searched the entire batch of files related to the Sinatra Theme for the string “Read More” and cannot find a single instance of it. If I could find that, I could just replace that with an empty string or otherwise alter the code. Does anyone know where it is?

Note: The posts are being generated on a Category page.

Thanks for any insight you may be able to provide.

Topic read-more Wordpress

Category Web


There are a few copies of 'Read More' in the files. I think the one you want is in template-parts/entry/entry-summary-footer.php.

However if you look at the code that includes this in content-blog-horizontal:

if ( sinatra_option( 'blog_horizontal_read_more' ) ) {
    get_template_part( 'template-parts/entry/entry-summary-footer' );
}

there's already a config option 'Show Read More Button' to turn this off. I don't know Sinatra to say where to find this in the admin site, but it should be there.

Regardless it's risky to actually edit the theme because any changes you make would get lost when the theme updates. It's safer to use filters / pluggables you set up in a plugin instead (as you've done for the excerpt function?) or a child theme to make changes.

About

Geeks Mental is a community that publishes articles and tutorials about Web, Android, Data Science, new techniques and Linux security.