WordPress links not working after permalink change
I have installed a wordpress on my server running on apache2. After wordpress installation I tried to change the permalink setup to
/%year%/%monthnum%/%day%/%postname%/
After the change pages are showing following error
Not Found
The requested URL /2011/03/14/hello-world/ was not found on this server.
Apache/2.2.9 (Debian) PHP/5.2.6-1+lenny9 with Suhosin-Patch mod_python/3.3.1 Python/2.5.2 mod_perl/2.0.4 Perl/v5.10.0 Server at <addressremoved>.com Port 80
Please help me
This problem happens manly because of two reasons.
1 ) One is the missing of .htaccess or write permission of the file
WordPress will give you following message on top of the permalink setup page
“You should update your .htaccess now.” That means WordPress doesn’t have rights to modify the .htaccess file
So create .htaccess file in document root with following content if it is not there
# BEGIN WordPress
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ – [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
# END WordPress
This is a manual creation method.
you can also give 666 rights to the file and solve the issue.
2 ) It can happen even if Module rewrite is not enabled.
Run following command to Enable mod_rewrite on Debian
# a2enmod rewrite
Was this answer helpful?
LikeDislike