• Resolved fovlet

    (@fovlet)


    This is my website: http://www.emilymorganti.com

    When I set up WordPress I put it in /blog, and was using it just to power my blog alongside a few hand-coded pages. I now want to use WordPress to power the whole site and I’ve started moving the hand coded pages into WordPress. Here’s one of them: http://www.emilymorganti.com/blog/contact

    I’m currently using the “Enhanced Custom Permalinks” plugin to make the permalink of the pages more user-friendly. Because WordPress is in my /blog/ directory, the user-friendly permalink displays as emilymorganti.com/blog/contact, but I want it to be emilymorganti.com/contact. [Note that emilymorganti.com/contact currently does redirect to to emilymorganti.com/blog/contact — I did that with an html redirect.]

    I tried changing the “site address” from emilymorganti.com/blog to emilymorganti.com in the WordPress settings, but when I do that all of my permalinks break because they change from something like http://www.emilymorganti.com/blog/?p=8244 to http://www.emilymorganti.com/?p=8244, which isn’t a valid URL.

    I thought I could fix this by switching to custom permalinks and adding “blog” back in. I tried to do this by adding /blog/?p=%post_id% into the custom permalink field in Settings, but that just made all of my blog posts and the main /blog page display with 404 errors.

    Can anyone tell me how to do this? Or alternatively if there’s a way for me to keep the Site URL set to emilymorganti.com/blog but rewrite the URLs for the few standalone pages to appear as emilymorganti.com/pagename instead of emilymorganti.com/blog/pagename, I’d be happy with that too. Basically I want it to look like the standalone pages are not in the /blog directory, but to keep all my blog posts in the /blog directory.

    I hope this makes sense. I’m not super savvy with this stuff, but I can make edits to .htaccess or to WordPress php files if I’m given instructions. Thanks!

Viewing 3 replies - 1 through 3 (of 3 total)
  • I would try doing this, specifically where it says: Using a pre-existing subdirectory install

    https://codex.wordpress.org/Giving_WordPress_Its_Own_Directory

    Thread Starter fovlet

    (@fovlet)

    Thanks. I had followed those steps but going through them again made me realize that the custom permalinks weren’t the problem. Some other stuff is being weird and I have to figure out exactly what’s going on, but at least under certain circumstances the custom permalink I entered is behaving like it should.

    I might be back with a different question after some more troubleshooting…

    Thread Starter fovlet

    (@fovlet)

    Sorry for the double post, I meant to “mark as resolved”.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Need help with custom permalinks’ is closed to new replies.