Forums

[resolved] Extra characters placed on the end of my permalink? (5 posts)

  1. hellodrifter
    Member
    Posted 1 year ago #

    I am learning about the read more tag <!--more-->
    and have a couple questions. I am using the custom permalink structure of /%year%/%monthnum%/%postname%/

    If I click on the linked title of the post, my url is spit out perfect on the single page.

    However, when I click on (more…)rather than simply spit out the name of my post in the url, it adds #more-16 after postname as seen below.
    e.g. wordpress/2011/05/this-will-be-a-long-one/#more-16

    Q1) Why is it doing this, and how can I stop the more tag from adding extra garbage at the end of my url?

    Q2) How do I remove the ( ) from around more... ?

  2. esmi
    Theme Diva & Forum Moderator
    Posted 1 year ago #

    1. Because it's linking to the precise point in your post were you placed the more tag. And it's not garbage - it's an in-document id link.

    2. See Customizing_the_Read_More.

  3. hellodrifter
    Member
    Posted 1 year ago #

    Thank you for your timely response esmi.

    Ah I see, so its function is similar to an internal bookmark anchor in HTML.
    e.g. <a name="Ambient Mixes">Ambient Mixes</a>

    I am glad that lovely functionality is included in the more tag, but in the process it's still adding rubbish to the end of my url. Now, to find a plugin or other method to take out the trash, while keeping that nice functionality.

    Thank you for the link, I hope to find my answer there.

  4. esmi
    Theme Diva & Forum Moderator
    Posted 1 year ago #

    so its function is similar to an internal bookmark anchor in HTML

    Exactly!

    If you don't want the more link id, you can suppress it by using <?php the_content('',FALSE,'');?> in your template files and then adding something like <a href="<?php the_permalink();?>"><?php _e('Continue reading ');the_title();?></a> to generate a "clean" url.

  5. hellodrifter
    Member
    Posted 1 year ago #

    Thanks very much for your advice esmi, I'll play around with your suggestion. :)

Topic Closed

This topic has been closed to new replies.

About this Topic