WordPress.org

Forums

Postname permalinks cause Page Not Found after auto update to 3.8.1 (43 posts)

  1. wordsword
    Member
    Posted 1 year ago #

    After the auto update to 3.8.1, when I publish a new post and click on View Post or Preview (or manually typing url), it shows me a Page Not Found error.

    My permalink settings is set to "Post name". The problem does not exist if I change the setting to "Default" or any of the other choices like "Numeric". But I need my permalinks to be based on post names. Other than the update to 3.8.1, no other changes were made to my site before this Page Not Found error starting happening.

    Here are the things that I have tried without success:
    1) I reinstalled 3.8.1 from the dashboard.
    2) I changed themes including one time to Twenty Fourteen.
    2) I disabled all plugins.
    3) I renamed the plugins folder (to test if a deactivated plugin may be the culprit).
    4) I checked the .htaccess file and made sure it includes this code:

    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>

    5) I changed the permission of .htaccess to 444, 644, and just about all the combinations available.
    6) I tried viewing the post when logged in vs. not logged in.

    Is there anything else I can try?

    Has anyone found a solution to this problem?

  2. Red Deer Web Design
    Member
    Posted 1 year ago #

    Same issues, same lack of results here. :-\

  3. Red Deer Web Design
    Member
    Posted 1 year ago #

    Current rewrite for custom post type:
    'rewrite' => array( 'slug' => 'products/%product-categories%' ),

    The custom %product-categories% seems to be breaking it, however only since 3.8.1.
    Ideas?

    Update:
    It's not actually that breaking it. It's the fact it's more than one level deep...

  4. Red Deer Web Design
    Member
    Posted 1 year ago #

    UPDATE:

    This is now working. As of version 3.1 'hierarchical' was added. Seem to do the trick... not totally understanding it yet though.

    'rewrite' => array( 'slug' => 'products', 'with_front' => true, 'hierarchical' => true ),

  5. karenleap
    Member
    Posted 1 year ago #

    I have the same issue with my site after upgrade (morphbody.com)

    I'm a bit new to WordPress - where should I put the above code?

    'rewrite' => array( 'slug' => 'products', 'with_front' => true, 'hierarchical' => true ),

  6. Red Deer Web Design
    Member
    Posted 1 year ago #

    I had set up custom post types in the function.php file. If you haven't set up any custom post types than this probably isn't the fix you area looking for.

    I don't see any broken links in your site though either...

  7. karenleap
    Member
    Posted 1 year ago #

    The problem is the blog article page (not the blog page); so that clicking on the title of the post or clicking the "more" link on the front page goes to a 404. The problem is solved by changing the permalinks to default, but that breaks all of the image and button links, and is inelegant besides :)
    But thank you for your answer. I have been searching for a couple of days, and although many people have this problem, there doesn't seem to be one solution that works for my site.

  8. Red Deer Web Design
    Member
    Posted 1 year ago #

    Has it just been since an update or has it never worked?

    Perhaps conflicting redirect code in the .htaccess file?

    Tried disabling all plugins?

  9. karenleap
    Member
    Posted 1 year ago #

    Just after the latest update I believe.

    I don't know much about coding, but this is the .htaccess file that was recommended:

    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>
    
    # END WordPress

    Also disabling plugins did not solve the problem, nor did switching themes (to 2012, and then 2013).

  10. Brian Jackson
    Member
    Posted 1 year ago #

    I have same issue here... tried disabling all plugins, switching themes... I ended up having to revert back to 3.8 for now until someone can figure this out.

    My .htaccess file is the same as above.

    See this similar thread earlier... http://wordpress.org/support/topic/cant-edit-page-after-auto-update-to-381?replies=8

  11. D
    Member
    Posted 1 year ago #

    Same thing happened to me on my site after wp update to 3.8.1

    I just rebuild the links by going to permalinks in wp admin and click save, it'll rebuild all the links.

  12. karenleap
    Member
    Posted 1 year ago #

    Yeah, that didn't work for me any of the approximately 125 times I've tried it over the last couple of days :)

    brianleejackson, did reverting back to 3.8 fix it? Is it still wortikng for you? I really don't want to do that, but if that's the only fix on offer, I'll go ahead.

  13. Red Deer Web Design
    Member
    Posted 1 year ago #

    That will really suck if it's been a 3.8.1 bug that really has no fix...
    I don't know how mine works - but it does. That was in the custom post types though. Other pages are fine.

  14. I
    Member
    Posted 1 year ago #

    This is not a bug with WordPress 3.8.1.

    @karenleap long shot but if you have access to phpmyadmin or know how to execute an SQL statement, try the following:

    UPDATE wp_options SET option_value = '' WHERE option_name = 'rewrite_rules';
    UPDATE wp_options SET option_value = '' WHERE option_name = '_transient_rewrite_rules';

    If this doesn't work then rest assured the most likely suspect is a plugin. Disable all your plugins (really disable all your plugins first), execute the above SQL statements, then re-enable each plugin one by one and checking your links each time.

  15. Brian Jackson
    Member
    Posted 1 year ago #

    Well I got mine fixed... mine turned out to be a security problem on a few of the folders (the group was set incorrectly). Not sure how this happened. Anyone having this issue and having tried all the normal troubleshooting steps, you might want to reach out to your host and have them check your permissions.

  16. karenleap
    Member
    Posted 1 year ago #

    i.ahmed: thanks for the hint. I do have access to phpmyadmin, but I have no idea how to execute an SQL statement. If you are able to, could you give me a bit more direction, for once I'm in phpMyAdmin - where exactly I should insert this script?

  17. I
    Member
    Posted 1 year ago #

    I can't provide you screenshots because they're disabled at work.

    1. In the left hand menu, click on your database name.
    2. You should see a list of tables in the left hand menu - look for wp_options or a table ending with _options and click it. There should only be one.
    3. In the right hand side you should see tabs labelled browse, structure, sql etc. Click on SQL.
    4. In the box under Run SQL query/queries on database, paste the code from above and then click the GO button.

  18. karenleap
    Member
    Posted 1 year ago #

    Thank you for doing that i.ahmed.

    I ran the SQL query, I went through all my plugins, still not working.
    It's frustrating because the links work just fine with the permalinks set to default. None of the other options work :( and I really hate to have those generic # pages for a business site.

  19. karenleap
    Member
    Posted 1 year ago #

    So I've tried every solution I've found for this problem, and I still am having it. If anyone happens across a new solution, please do post it. In the meantime I will change back to default permalinks and take my chances :(

  20. @i.ahmed Please do not ask people to post their contact information in these forums.

  21. cobalt2
    Member
    Posted 1 year ago #

    Today I also discovered my permalinks had all been changed by the auto 3.8.1 update. Before they just used post titles. Now the date had also been added. So I changed them back to just post titles. At which point all links brought them to my most current blog page with "Page not Found at the Top." For the next few hours I searched for a solution. Nothing. Then I decided permalinks with post titles with dates are better than post titles that can't be found at all so I changed them back again and will keep them that way till a solution is found. Site is http://savvysavingbytes.com/

  22. Red Deer Web Design
    Member
    Posted 1 year ago #

    The problem is going to be any incoming search engine links. Google will be directing visitors to your old links still until it re-indexes all of them.

    :-\

    Still no solutions out there eh?

  23. cobalt2
    Member
    Posted 1 year ago #

    My Google traffic is way down this morning. Last night even though I changed my permalinks to post title and date Google is now directing visitors to my site with just post titles (which I had originally before this unfortunate auto 3.8.1 update). Still the links seem to be working as haven't seen "Page not Found" yet.

    Don't know if it's connected but when I try to get into my Maintenance Mode plugin settings, I'm now informed I don't have sufficient permission.

  24. karenleap
    Member
    Posted 1 year ago #

    Cobalt, using your example, I changed my permalink setting to date with name, and they now work. So yes, I agree that is better than some generic number. Luckily the site is still in development, so there won't be too much of an issue with google.

    I will keep looking for a reason though, and post it when/if I ever find one!

  25. JayKayBe
    Member
    Posted 1 year ago #

    Same problem here. My site also is in developement, but unfortunately I have to get my permalinks to the be /%postname% as I have 25.000+ old links in this format that have to be reachable on the new site.
    If anybody finds a solution to this please share, I will do the same!

  26. HorstGrundke
    Member
    Posted 1 year ago #

    Having decided to finally learn WordPress, I did a local WAMP install using WordPress 8.3.1. I started with the Twenty Fourteen theme, and I installed no plugins or made any other changes. I created one simple About page, but got the same "requested url not found" error when I clicked on it with ANY permalink setting except "default". Changing to other themes made no difference. Based on the simplicity of my situation, it's hard to see how this can be anything OTHER than a bug in the 8.1.3 release, and none of the suggested fixes or workarounds here had any effect. Bottom line: I'm thinking of uninstalling WordPress and starting fresh with an older version.

    Good idea? If so, what version?

  27. The Fagan
    Member
    Posted 1 year ago #

    To make SEO more effective they say we must change pagename url permalinks. According to old versions of WP you could change page and post page-name permalinks by clicking on 'edit' next to the page url. But now you only have 'view page' and 'get shortlink'. I have been to settings/permalinks but if I change it to 'post name' I have to edit htaccess. That makes me nervous because I don't know how to do that or where in the block below. Please could someone very kindly put it in simple layman's jargon for un-tech people like me to understand how and where it is done! Many thanks. My site is http://adafaga.co.za

  28. The Fagan
    Member
    Posted 1 year ago #

    Sorry there was a miss print: my site is http://adafagan.co.za

  29. wpdunn
    Member
    Posted 1 year ago #

    I'm having the same problem. I installed wordpress in its own directory (i.e. wordpress) and the permalinks "post name' worked fine there. However, when I tried to make my site active using the documented procedures for moving index.php and .htaccess to my root diectory, the permalinks would no longer work (404 errors). I tried moving all of wordpress to my root (GoDaddy has an easy way to do this) but still no luck. However, when I changed to the permalink 'default' (i.e. page_id), everything started working. However, anytime I try to change to 'post name' it breaks again. With 'default' my .htaccess file has no entries between the '# BEGIN WordPress' and '# END WordPress' at the beginning of the file. However, there is the following rewrite rule still at the end of the file:
    # BEGIN wtwp_security
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /wordpress/
    RewriteRule ^wp-admin/includes/ - [F,L]
    RewriteRule !^wp-includes/ - [S=3]
    RewriteRule ^wp-includes/[^/]+\.php$ - [F,L]
    RewriteRule ^wp-includes/js/tinymce/langs/.+\.php - [F,L]
    RewriteRule ^wp-includes/theme-compat/ - [F,L]
    </IfModule>
    <Files "wp-config.php">
    Order allow,deny
    Deny from all
    </Files>
    Options -Indexes
    # END wtwp_security

    I'm not sure what this means but it doesn't seem correct since there is no longer anything in the wordpress subdirectory. Can anyone help? Thanks.

  30. esmi
    Forum Moderator
    Posted 1 year ago #

    If you require assistance then, as per the Forum Welcome, please post your own topic.

Topic Closed

This topic has been closed to new replies.

About this Topic