Ask your WordPress questions! Pay money and get answers fast! Comodo Trusted Site Seal
Official PayPal Seal

Remove /portfolio/ from URL WordPress

Hello,

I am using the Virtue theme ( http://themes.kadencethemes.com/virtue/ ) and am having issues with my Permalinks.

This theme uses a Portfolio post type, which is great, though I am needing to use it more like pages. I want to remove the "/portfolio/" from the URL so that it reads "mysite.com/post-title" rather than "mysite.com/portfolio/post-title"

I have already done the following with no success:

- Installed "Custom Post Types Permalink" plugin
- gone into the "post-types.php" file and changed 'rewrite' => array('slug'=>'portfolio') to 'rewrite' => false, though this option fixed my URL problem, when I went to view my Portfolio post I was directed to a 404 Page Not Found error page.

site is www.bendpinenursery.com

What code/files do I need to change to allow Portfolio posts to be posted without a 'portfolio' slug and still show up on the site?

Answers (4)

2015-03-31

timDesain Nanang answers:

hopefully this will help you:
http://colorlabsproject.com/tutorials/remove-slugs-custom-post-type-url/


paulwagenblast comments:

THANK YOU - this worked perfectly!!!


timDesain Nanang comments:

glad to hear that


paulwagenblast comments:

UPDATE:

Is it possible to narrow this down to just one type of custom slug? I am also using WooCommerce and now all the products (which use a "products" custom slug) are coming up with a 404 error after having their slug removed.

2015-03-31

Reigel Gallarde answers:

when you got "404 Page Not Found" error page, did you try going to permalinks settings and update it?

I was thinking you already got it. but the permalinks were just not updated yet. that's why you are getting 404. You can try visiting Dashboard: Settings -> Permalink

2015-03-31

Romel Apuya answers:

resaving your permalink will fix that.
if not delete ur .htaccess and save permalink.

2015-03-31

Ian Lincicome answers:

If I understand your problem correctly, this link should explain exactly how to fix your issue:
https://wordpress.org/support/topic/how-to-fix-permalink-postname-404-not-found
Good luck!