Search code examples
wordpresswordpress-themingpermalinksroots-sage

Strange Permalink Issue


I've been dealing with a really strange Permalink Issue on my WordPress site which runs Sage 8.5.1, previously setup by another developer.

Yesterday, I made a new homepage live on my site within Settings > Reading, and after doing this the permalinks within my site seemed to stop working completely. I was using the setup: /%postname%/, when switching to the generic: ?p=123, all my links worked again.

I did quite a lot of testing, checking .htaccess file, deactiving plugins, going back a code version and other things.

This morning, the last thing I tested was activating the generic WordPress theme and then testing my permalinks (/%postname%/), and they worked. I then reactivated by original theme built on Sage 8.5.1, and all my links worked again with the original permalinks setup.

Has anyone come across this before? Its very strange, and I can't see why deactivating the theme, and then activating it would fix the problem.


Solution

  • Turns out it was something to do with a custom post type I setup. I removed the custom post type, and created a new one based on the WordPress codex and that solved the problem.