Support » How-To and Troubleshooting » Changing URL of a category

Changing URL of a category

  • Hello,

    I want to have Category URL changed.
    But, I fear of losing SEO with this.

    — Current URL: http://www.example.com/category/travel/photos
    — Want it to be: http://www.example.com/photos

    —— This is an important section of the blog, so don’t want to mess it.

    Can somebody please suggest me best way to do this?

    I have searched over Google and forums too, have found useful things. But still not sure how should I approach it in the best way?

    They talk about 301 and all, which is something I am not much familiar with.

    Any help will be heartily appreciated, mates.


Viewing 4 replies - 1 through 4 (of 4 total)
  • a 301 redirect is what you need. go to WP Docs and search 301 redirect.

    Hello mate,

    Thanks for your time to talk here.

    Is this the link you’re referring to: http://codex.wordpress.org/Function_Reference/wp_redirect

    If yes, how should I use this?
    And, how to change the URL to remove “/category/travel/”

    And, how to change the URL to remove “/category/travel/”

    ‘edit permalinks’ on the edit page screen. But this will temporarily wreck SEO. A good content site can rapidly reappear in google anyway.

    Wiki on 301

    So, first make a new page that’s a top level page, and call it photos. Use it from now on.
    In header.php, add

    <?php if (is_page(‘ — ‘)){
    <?php wp_redirect( ‘http://www.example.com/photos’, 301 ); exit; ?>
    } ?>
    <?php endif; ?>

    That will make the page number — redirect to example.com/photos and update google as well at the same time. To find the page number, go to Dashboard>pages and click edit on the existing photos page. look at the URL: in there will be a page ID or ?page=123 bit. pop that number in the code in place of —.

    Make sense?

    Yes, does.

    Seems a solution to me.
    Thanks, a lot.

    Please do not close the topic, until it is fully resolved.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Changing URL of a category’ is closed to new replies.