Viewing 4 replies - 1 through 4 (of 4 total)
  • I think it doesn’t matter, since # mark a specific ID inside your post, so when the URL is marked with # is opened in a browser, the browser will directly show the content from the ID that marked with # (not from the beginning of the page).

    If you insist to change this default behavior, you can implement the the_content_more_link() filter, and remove the # part from the link.

    Thread Starter markoburns

    (@markoburns)

    any idea if this doesn’t work in 3.0 as I just get errors when I put it in functions.php?

    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');

    what error messages?

    did you enter the code within the php tags?
    into functions.php of your theme?

    php errors are often from unclosed brackets and mixed up html/php tags.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘how to remove /#more for cleaner url’ is closed to new replies.