Jaye Tan's Octopress Blog

Just Blogs

Wordpress Permalinks 404 Not Found

Wordpress Permalinks 404 not found

This is mainly a problems for Ubuntu users after installing the Wordpress on their localhost. to solve this problem follow this instructions:

Using Terminal

first allow overides on your apache sudo gedit /etc/apache2/apache2.conf and find all <Directory /> </Directory> and paste this code in between in all of that tag

Options FollowSymLinks
AllowOverride All
Order allow,deny
Allow from all

ex. <Directory />

Options FollowSymLinks
AllowOverride All
Order allow,deny
Allow from all

</Directory>

then go to your wordpress folder usually you can find it on /var/www/html/wordpress then create an htaccess by typing:

sudo touch .htaccess then change the access permission by typing: sudo chmod 664 /var/www/html/wordpress/.htaccess then change the ownership by typing: sudo chown www-data:www-data /var/www/html/wordpress.htaccess take note of the path you may need to change it depending on where you wordpress is installed.

Then change the grant access to the www folder:

sudo chmod -R 777 /var/www
sudo chown -R **yourusername** /var/www

then type this in your terminal sudo a2enmod setenvif headers deflate filter expires rewrite include

then refresh the apache by: sudo service apache2 restart

you can now change your wordpress permalinks to Post name without an 404 error not found.