Support » Fixing WordPress » Remove the /category/ from url

  • Hello-
    How is it that I can remove the category from the path? If not how can I change the name and have it still function as a url?
    I tried changing the default category to a useful word like “wireless”
    Once I did that the url name changed correctly, but the link didnt work, and I could not change the path of the post from withing the Post settings..
    I would really like to remove the word /category/ all together, just leaving the actual name of the category….
    I have not noticed this with my 2.9.2 wp site btw..
    Many TIA

Viewing 7 replies - 1 through 7 (of 7 total)
  • If you want to change it go to Settings -> Permalinks

    Then change Category base to what you want the word Category changed to in the URL.

    As for removing it, never tried.

    Hi,

    In order to remove it from the permalink settings of category, you need to first backup your .htaccess file. After that open it and add this code:

    RewriteRule ^category/(.+)$ http://www.yourblog.com/$1 [R=301,L]

    Now, If your categories page default URL is:

    http://www.abc.com/category/

    Once you save above code in htaccess, it will be set at:

    http://www.abc.com/

    That’s it!

    Thanks,

    Shane G.

    Thread Starter parentalcontrolapps

    (@parentalcontrolapps)

    Thanks for your replies!
    I have a custome structure like this:
    /%category%/%postname%/
    thinking that it would not utilize the word category.
    Maybe I should use a useful word for the permanent “category” word and republish the post and it will work, i dunno.

    You wont need to republish if you change it.

    FYI, I always use

    /%postname%.html

    for my permalinks. I just find that I like that one the best. 🙂

    Thread Starter parentalcontrolapps

    (@parentalcontrolapps)

    It is very strange. If I change the name of the category in the optional section of the permalink page to something useful like “setup” then it breaks all posts when you try to access them via their category…
    When I put it back to the default where the word category is in the path then all the posts under each category are viable again.
    Where am I missing the point? If I change the default category name, where else do I have to go and make changes so the url will include the New name of “setup” instead of the defaul name of “category”
    Is there some setting in the category widget that makes it not adjust?

    Should work.

    Did you go back to your homepage and refresh the site first? Maybe clear the cache in your browser.

    Thread Starter parentalcontrolapps

    (@parentalcontrolapps)

    Thanks but there is something missing.
    I went to permalink and added the optional, instead of category I used “setup” .
    If you go to the site and click one of the links under the category widget then it takes you to:
    http://www.wirelessroutersetups.com/setup/wireless-router-setups/dlink/
    for instance, but the posts that are IN the dlink category do not show up.
    if I change it back it works but the path obviously says category.
    -Note I am not TOTALLY against the word category, however I would like it to be more specific to my genre’. I am more concerned at this point that this function of 3.0 might not work properly, I am using the default twentyten theme…
    Thanks fellas

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Remove the /category/ from url’ is closed to new replies.