WordPress.org

Ready to get started?Download WordPress

Forums

Permalink issues - 404 errors and out of ideas (15 posts)

  1. tom0311
    Member
    Posted 11 months ago #

    Hi,

    I have had my blog up and running a few days now, all going smoothly until I tried to change my permalinks for SEO, as the Yoast plugin advised. I've selected the 'month and name' setting.

    I have modified my /usr/share/wordpress/.htaccess file to what WordPress admin panel told me to. It still couldn't write to it even though I resorted to 777 after it kept failing. This in turn makes me doubt whether I'm even using the right file although it's the only one.

    I have mod_rewrite installed and running with apache2, which I have triple checked with 'a2enmod rewrite'

    My .htaccess file is (as directed):

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

    Whenever I go to a post now I get a 404, this is the apache log snippet:

    [Tue May 07 18:48:53 2013] [error] [client 5.65.18.60] File does not exist: /var/www/wordpress/2013, referer: http://engineers-brain-dump.co.uk/

    I also get:

    [Tue May 07 18:48:44 2013] [error] [client 5.65.18.60] PHP Warning: constant(): Couldn't find constant WP_CORE_UPDATE in /usr/share/wordpress/wp-admin/includes/update.php on line 33, referer: http://engineers-brain-dump.co.uk/wordpress/wp-admin/options-permalink.php

    I'm pretty lost now, and it's my first site so I'm new to wordpress. I've read loads of forum posts but can't find anything I haven't already tried. Any tips?

    Cheers

  2. govpatel
    Member
    Posted 11 months ago #

    http://engineers-brain-dump.co.uk/ is this your url seems as if is working fine on default setting.

  3. tom0311
    Member
    Posted 11 months ago #

    Yeah I changed it back to default so I could edit some posts. I'll change it back to broken for a while if you want to see it break. Any post or category links break and bring a 404 error.

    ***EDIT***

    I've set it back to 'month and name', click any category or post and it breaks although the home page works.

  4. govpatel
    Member
    Posted 11 months ago #

    Where did you add that custom permalink did you use the one in list in Settings>>>> permalink if so looks like there must be problem on your settings on server as .htaccess file rewrites the url. when change to default .htaccess does not rewrite url.

  5. tom0311
    Member
    Posted 11 months ago #

    I used the setting 'month and name', and then copied the modification to my .htaccess file like the admin panel told me to. It couldn't write to the file so I did it manually. Restarted apache2, made sure mod_rewrite was running and bam, 404 :(

  6. govpatel
    Member
    Posted 11 months ago #

    What ever the problem is with your .htaccess file or Mod_rewrite

  7. tom0311
    Member
    Posted 11 months ago #

    How can I rule out either? Any ideas? If it's taking me to the permalink and not finding the file which part is to blame?

  8. esmi
    Theme Diva & Forum Moderator
    Posted 11 months ago #

    That sounds like an issue with the server - maybe a problem with mod_rewrite.

  9. govpatel
    Member
    Posted 11 months ago #

    If you copied the code that wordpress gave you as is in .htaccess file then most likely is Mod_rewrite problem.Have you tried any other permalink settings like postname

  10. tom0311
    Member
    Posted 11 months ago #

    I've just tried postname, and I get exactly the same thing :(

    [Tue May 07 21:24:00 2013] [error] [client 5.65.18.60] File does not exist: /var/www/wordpress/how-to-make-your-own-button-in-phpbb-reply-editor

  11. govpatel
    Member
    Posted 11 months ago #

    That means is diffidently problem with server settings for Mod_rewrite.

  12. tom0311
    Member
    Posted 11 months ago #

    Ok - thanks :)

    I'm just looking up AllowOverride etc, my server's httpd.conf file is blank - should this be the case?

  13. tom0311
    Member
    Posted 11 months ago #

    I've changed the file /etc/apache2/sites-enabled/000-default, all references to AllowOverride are now 'All'. Still no dice :(

    I'll have to keep digging for now - thanks for the pointers so far.

  14. newfictionwriters
    Member
    Posted 11 months ago #

    I recently switched from a drupal theme to a wordpress theme and some of my permalinks are sending ifo to the develop site. I least I guess thats whats happening. I get this message.
    Forbidden
    You don't have permission to access / on this server.

    Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.

    --------------------------------------------------------------------------------

    Apache Server at develop.newfictionwriters.com Port 80

    I don't know what to do any suggestions?

  15. Krishna
    Volunteer Moderator
    Posted 11 months ago #

    newfictionwriters,
    By posting your question on someone's thread, you are creating confusion. Please continue with your thread:
    http://wordpress.org/support/topic/permalinks-147?replies=3

Reply

You must log in to post.

About this Topic