404 after publish of a page

Posted in: Newspaper
Post count: 3

I have created a page. When the page is in “Draft” mode, I can preview the page with no problem. When I press “Publish” and then try to preview the page. I get a 404 error. I can still see the page in the Admin, just not view it.

If I switch the page back to “draft” mode, then I can again preview the page.

Also, accessing the page URL directly when published also gives a 404 error.

Post count: 3

I have narrowed it down some.

If I change the site “PermaLink” settings to “PostName” so https://blog.marineadvisor.com/%postname% then it does not work. If I return the value to “Plain”, then it does work. Is there some issue with Mod-Rewrite?

Post count: 3

Issue resolved.

I needed to add a .htaccess file in my wordpress directory.
I added the following content to the .htaccess file.

RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . index.php
ErrorDocument 404 /index.php

Viewing 3 posts - 1 through 3 (of 3 total)
The forum ‘Newspaper’ is closed to new topics and replies.