Step1.
- Log on to WordPress admin.
- Go to Settings>Permalink Settings.
- On Common settings choose Custom Structure
- Set /%postname%/ on input box given.
- Click Save Changes.
Step2.
Now add an .htaccess file on the blog’s root folder .
Put the following code in the .htaccess file
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /blog/
RewriteRule ^index\.php$ – [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /blog/index.php [L]
</IfModule>
Note:- here blog is root folder name for WordPress files.
Now follow the Step 3 if URL’s still not working. Your server may not have the AllowOverride directive enabled. In this case, .htaccess files are completely ignored.
Step3.
- logon to webmin.
- Click on Server from side menu.
- Click on Apache Webserver side menu.
- On Existing virtual hosts tab Find servers where Server Name equals to <websitename.com>
- Click on the Virtual Server link for which port no is 80.
FYI,
- Port 80 is generally used for website.
- Port 443 is generally used for SSL.
- Now on Virtual Server Options; Click on Edit Directives.
- Add following code below the last Directory tag code to allow override.
<Directory /var/www/html/full_ path_ to_ the_ directory>
AllowOverride All
</Directory>
example-
<Directory /var/www/html/yoursite/blog>
AllowOverride All
</Directory>
- Save changes.
- You must restart your Apache server for any httpd.config file changes to take effect
- Carefully click on the Apply Changes RHS.
Hope this helps.. if still get sucked follow the link below.
http://codex.wordpress.org/Using_Permalinks

Pingback: On page Optimization | The On Page SEO Basics | Sagebridge Digital | Sagebridge Digital