Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I would like to overwrite my URL on single blog posts. At the moment my posts are displaying as www.mydomain.co.uk/post-title, however I would like them to be as www.mydomain.co.uk/blog/post-title so /blog/ always displays before post item, I've tried to do that from permalink level but when I put /blog in Post name box it works, however all my single Custom posts are displaying as /blog/custom-post-item which is not what I'm after as I would only like that to happen for blog posts and not for custom post types.

Any tips.

Many thanks

share|improve this question
add comment

1 Answer 1

If you are not using Custom Post Types the following in your permalink settings should work just fine.

/blog/%postname%/

Screenshot

(Below can still be applicable depending on your use of custom post types)

Keep your regular permalinks on blog like you have it in settings. And in your custom post type arguments the "with_front" Boolean field will help you achieve what you are looking for.

...
'rewrite' => array(
    'with_front' => false,
    'slug' => 'your-slug'
),
...

More info about rewrites here http://codex.wordpress.org/Function_Reference/register_post_type

share|improve this answer
    
Thank you very much for your answer, sorry I wasn't clear enough those are not custom posts but core WP posts types so there is no custom posts type argument in my function.php –  jmysona Feb 18 '13 at 18:05
    
Can you clarify "however all my single Custom posts are displaying as /blog/custom-post-item which is not what I'm after". What are you referring to as a single custom post. post_type = post? or something else? –  Cole Feb 18 '13 at 18:17
    
Yes that is correct post_type=post –  jmysona Feb 18 '13 at 18:26
    
Then my edit above should work properly. –  Cole Feb 18 '13 at 19:02
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.