WordPress.org

Ready to get started?Download WordPress

Forums

How to change TAG url (4 posts)

  1. bndrz
    Member
    Posted 5 years ago #

    Hello.

    I would like to know how to change :

    http://example.com/tag/tag-name/

    to

    http://example.com/tag/tag-id/

    Thank you.

  2. Samuel Wood (Otto)
    Tech Ninja
    Posted 5 years ago #

    You can't do that. Tag URLs don't work that way.

    A very custom plugin could do it by messing with the rewrite stuff, but it seems like a bad idea. Tags are organized by tag, not by ID.

  3. bndrz
    Member
    Posted 5 years ago #

    Well as i can see in admin panel the tags get each unique id and you can call them up in admin panel like:

    http://example/wp-admin/edit-tags.php?action=edit&tag_ID=100

  4. Samuel Wood (Otto)
    Tech Ninja
    Posted 5 years ago #

    Yes, but that's not what you're asking for. You're looking to change the rewrite URLs, which is a whole different kettle of fish. It would be one thing to just change the style of the URL, but to change the actual content from tag to ID is something else entirely.

    It's a non-trivial problem. Just because tags have IDs does not mean that the system has code to a) pull ID's out of a URL and b) query for the posts in the Loop based on that ID.

Topic Closed

This topic has been closed to new replies.

About this Topic