Force the “read more” to display on pages.
Suppose you have created a page template that calls up a couple categories and you want them to display the read more link inside of the standard [...] that WordPress will insert if you use the_excerpt in your WordPress loop.
Stop the read more link from “jumping” when going to the post by adding this to your theme’s functions.php:
//remove read more jump
function remove_more_jump_link($link) {
$offset = strpos($link, '#more-');
if ($offset) {
$end = strpos($link, '"',$offset);
}
if ($end) {
$link = substr_replace($link, '', $offset, $end-$offset);
}
return $link;
}
add_filter('the_content_more_link', 'remove_more_jump_link');
No Comments so far ↓
There are no comments yet...Kick things off by filling out the form below.