I have a WP installation that needs moving to a new site URL.
I have tried the usual methods listed on this codex. All of them produce the same problem. When I hit a link like this on the site:
The web server receives says:
The requested URL /path/to/post/ was not found on this server.
This is even if I paste the URL into the browser.
Note that some URLs DO work, for example to this CSS file:
But NOT to blog posts.
EDIT with more info
When I view the source of the pages, I see that all hrefs are in fact correct. However, when clicked on, the links to the posts (but not to CSS files) are missing the "http://" prefix and are instead rendered as server-root relative URLs.
So my change to the siteurl option is being made, but something about the site in question is breaking some (but not all) URLs.
I have since tried a vanilla fresh install of WP and changed the siteurl for that at it does NOT exhibit this problem so I assume it's something in the WP install for this site.
The problem persists even when I try the following:
- Removing all .htaccess files
- Deactivating all plugins
- Viewed using incognito mode.
- Using another web browser to load the site (had been using Chrome, installed and used a fresh installation of Firefox)
- Switching to a different theme (twentynineteen)
- Putting one of the broken URLs into a plain .html test file