Disable jumping to the middle of page on Read More Wordpress
When I inserted Read More tag in my WordPress site blog entries then the blog post opens in the middle of the page so reader left wondering what the beginning of the page is. After researching on internet I found a solution from HostPapa.
Go to your Word Press Back End Dashboard - Appearance - Theme Editor and locate function.php in Them Files. Then add the following code at the beginning of the function.php file - I added at the end and it didnt work. Then I added the following function to disable showing post in the middle:
function remove_more_link_scroll( $link ) { $link = preg_replace( '|#more-[0-9]+|', '', $link ); return $link; } add_filter( 'the_content_more_link', 'remove_more_link_scroll' );
at the beginning of the function.php file after the following:
<?php
if ( ! function_exists( 'shoreditch_setup' ) ) :
And hurray! It worked!
Comments
Post a Comment