How to install wordpress on windows server / IIS6 with natural permalink
WordPress is a state-of-the-art publishing platform with a focus on aesthetics, web standards, and usability. WordPress is both free and priceless. More simply, WordPress is what you use when you want to work with your blogging software.
To run WordPress your host just needs:
Wordpress recommend Apache or Litespeed as the most robust and featureful server for running WordPress, but any server that supports PHP and MySQL will do.
This post gives guidance on installation of wordpress on Windows Server / OS that run IIS6.
An easy solution for wordpress installation problem on host behind Windows Server and IIS 6.0, plus hosting provider does not allow mod_rewrite patch. After following this guide, you get SEO friendly Pretty Permalinks.
To run Wordpress on your host that behind Windows Server and IIS6 is quite simple as Apache or Litespeed but you do keep in mind following issues.
- Pretty Permalinks does not work properly.
- Pretty Permalinks work on some host if user apply some hacks.For more information http://codex.wordpress.org/Using_Permalinks
- Pretty Permalinks work on if mod_rewrite patch is installed. But only few host support and install mod_rewrite patch on Windows Server. Mod-Rewrite Pro
- Windows Server and IIS does not supports mod_rewrite default.
- PATHINFO permalinks look very much like mod_rewrite permalinks but for one exception: they have /index.php inserted before them, like so: http://example.com/index.php/yyyy/mm/dd/post-name/
- Using IIS 404 redirect hack provides Pretty Permalinks but user do include index.php in Pretty Permalinks. a 404 handler
- Pretty Permalinks must include ‘index.php’
- Giving WordPress its own directory while leaving your blog in the Root Directory, home page always get 404 file not found error.
- Searching not work, Search result always displays default home page.
If you are use wordpress for wordpress shopping cart, wordpress photo gallery, Photo blog, Magazine, Online Shop, as a CMS, blog for money, or other business usage, you site must have SEO friendly urls and so Pretty Permalinks is very important.
Many of SEO masters say: ‘including index.php in Permalink is not a fully SEO link.’
This is a solution for same. This solution is divided in five sections:
1. Recommend requirements :
- PHP version 5.2 or greater
- MySQL version 4.0 or greater
- IIS 6.0 with CGI
- Ability to set ‘404 file not found’ error page.
- Wordpress 2.6 or greater
2. Installing Wordpress :
- Download and unzip the WordPress package from http://wordpress.org/download/
- Create the Database and a User. If you determine that you’ll need to create one manually, follow the instructions for accessing phpMyAdmin on various servers, or follow the instructions for Using cPanel or Using phpMyAdmin below.
- Set up wp-config.php. You can either create and edit the wp-config.php file yourself, or you can skip this step and let WordPress try to do this itself. Please see Editing wp-config.php.
- Enter your database information under the section labeled.
- Upload the files in the root directory of your web site [ compulsory] .
For more information on installing Wordpress:
- http://codex.wordpress.org/Installing_WordPress
- http://www.bloggingpro.com/archives/2006/06/19/my-wordpress-install-process/
- http://www.howtomakemyblog.com/wordpress/how-to-install-wordpress-step-by-step-guide/
- http://www.webdesignerwall.com/tutorials/installing-wordpress-locally/
- http://wordpress.tv/2009/02/09/installing-wordpress-with-ftp/
- http://maczealots.com/tutorials/wordpress/
- http://blogbuildingu.com/wordpress/install-wordpress-wlmp
- http://www.dailyblogtips.com/trouble-installing-wordpress-try-easywp-install/
3. Setting SEO Permalink Structure :
Go to the ‘Customize Permalink Structure’ page in your Wordpress Admin : Dashboard>Options>Permalinks. Then select the ‘Custom Structure’ Option.
use :
/%category%/%postname%/
or
/%year%/%monthnum%/%day%/%postname%/
or
/%year%/%monthnum%/%postname%/
By default, your WordPress Dashboard gives you a 3 choices to choose from. The default permalink structure is a terrible option from an SEO standpoint and the other two aren’t bad, but they aren’t your best option.
For more information on SEO permalinks structure:
- http://enlightenedwebmastery.com/best-seo-wordpress-permalink-structure
- http://www.weberz.com/blog/2009/06/seo-experts-give-wrong-advice-wordpress-permalinks
- http://www.gnc-web-creations.com/wordpress-urls.htm
- http://yoast.com/articles/wordpress-seo/
- http://www.wolf-howl.com/seo/url-configuration-wordpress/
- http://bloggingbits.com/wordpress-permalinks-seo/
4. Apply these hacks :
- Create php.ini file paste following code and upload to site’s root.
cgi.fix_pathinfo = 1
cgi.force_redirect = 0
max_execution_time = 0
max_input_time = 300 - Create 404.php file, paste following code and upload to site’s root.
- Set your sites 404 page to point to the 404.php URL. Most control panels at web hosts allow you to do this. If you’ve got the option to select between FILE and URL then choose URL.
-
For more information on SEO permalinks structure:
- http://michael.tyson.id.au/wordpress/plugins/smart-404/
- http://tech.einaregilsson.com/2007/07/30/pretty-wordpress-permalinks-on-iis/
- http://chrisjohnston.org/2009/setting-up-a-wordpress-blog-on-lighttpd
- http://www.easycgireview.org/easy-cgi-wordpress-blog-running-in-iis
- http://www.fusionteam.co.uk/blog/2007/12/04/wordpress-iis-permalinks-using-404-redirect/
- http://www.searchenginejournal.com/seo-friendly-url-structure/4556/
- Search Result hack:
Open wp-include/formatting.php and go to at line number 2070 in clean_url function and paste this code before return apply_filters(‘clean_url’, $url, $original_url, $context);.
<?php $file_name = $_SERVER['REQUEST_URI'];$lowercase_file_name = strtolower($_SERVER['REQUEST_URI']); $_SERVER['REQUEST_URI'] = substr($_SERVER['QUERY_STRING'], strpos($_SERVER['QUERY_STRING'], ':80')+4); $_SERVER['PATH_INFO'] = $_SERVER['REQUEST_URI']; /* if found ';' before http://www change ':80')+3 to ':80')+4 */$param = $_SERVER['PATH_INFO'] ; if ( !empty($param) ){ include('index.php'); }else{ include('index.php'); }?>
/* Add this code
wp-include/formatting.php - after line no 2070
before apply_filters
*/
$mystring1 = $url;
$findme = '?s=';
$pos1 = stripos($mystring1, $findme);
if ( $pos1 !== false )
{
$url = str_replace('/page/','/index.php/page/',$url);
//$url = str_replace('index.php/Index.php','index.php',$url);
}
/* end */
5. Check your web site :
- Check your site’s home page and all next/previous page
- Check for category pages and all next/previous page
- Check for tags pages and all next/previous page
- Check for archive pages and all next/previous page
- Check for Search and all next/previous page
- Check for all pages
If you like this post, share it and leave comment reply for any suggestion.










Hi, Onload of page my antivirus put alert, check pls.
DingoDogg
I like this site very much.
This is such a outstanding site.
And it is not like other money bound website, the info here is genuinely helpful.
I am definitely bookmarking it as well as sharing it with my friends.
I am definitely bookmarking this page and sharing it with my friends.
Dear Author http://www.imagingdesk.com !
Excuse, that I interrupt you, would like to offer other decision.
Thanks, dear prosto_kursant,
Step ‘5. Search Result hack’ of section ‘Apply these hacks’ is updated. It is a hack to remove extra/add index.php from pagination that generate ‘404 file not found’ error.
Thanks again.
Author
Ujamshi Khandla
http://www.imagingdesk.com
Very outstanding site.
The message here is truly useful.
I will refer it to my friends.
Cheers
Such a great site. I am saving this page.
I somehow dont agree with a few things, but its great anyways.
I want to quote your post in my blog. It can?
And you et an account on Twitter?
This brings me to an idea:…
Great idea, thanks for this tip!
Damn, that sound’s so easy if you think about it.