Truemag

  • Categories
    • Tips And Tricks
    • Internet
    • PHP
    • Javascript
    • CSharp
    • SQL Server
    • Linux
  • Lastest Videos
  • Our Demos
  • About
  • Contact
  • Home
  • Write With Us
  • Job Request
Home Internet How To Configure Friendly URL For WordPress Hosted On IIS

How To Configure Friendly URL For WordPress Hosted On IIS

With URL Rewrite Module in IIS 7 Microsoft Windows, you can easy to make the WordPress Permalinks nicer and optimize for Search Engine Friendly URL. Before, WordPress which is hosted on IIS typically start with “index.php” in the Permalinks, ex: http://4rapiddev.com/index.php/category-name/post-name/ but nowadays, it’s easier for us to make the Permalinks more pretty (without the index.php) exactly the same with using .htaccess in Apache. The configuration makes your URLs a little bit shorter and more professional.

Firstly, make sure that you have completed the install PHP on IIS 7 with FastCGI module.

After that, download and install the latest stable version of WordPress. I assume that you completely understand and follow all steps to make your WordPress up and running on your IIS.

Below is the main part:

1. Update Permalinks settings

  • Login to the Site Admin as an Administrator
  • On Settings section, click on Permalinks tab
  • On the Permalink Settings page, select Custom Structure option under Common settings and type: /%category%/%postname%/
  • Click Save Changes button
WordPress custom permalink settings

WordPress custom permalink settings

Hand on, it has not finished yet, please continue to step 2.

2. Create Rewrite Rule in Web.config file

Firstly, you need to download & install the URL Rewrite module on the IIS:

  • Download the x86 version of the URL Rewrite module
  • Download the x64 version of the URL Rewrite module

After that, let create a Web.config file in the WordPress folder, if it’s not existed then copy and paste the XML settings below:

[xml]

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.webServer>
<handlers>
<add name="PHP via FastCGI" path="*.php" verb="*" modules="FastCgiModule" scriptProcessor="C:\php_536\php-cgi.exe" resourceType="Unspecified" />
</handlers>
<rewrite>
<rules>
<rule name="Main Rule" stopProcessing="true">
<match url=".*" />
<conditions logicalGrouping="MatchAll">
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
</conditions>
<action type="Rewrite" url="index.php" />
</rule>
</rules>
</rewrite>
</system.webServer>
</configuration>

[/xml]

Note: it’s copied from my environment, please update the scriptProcessor value with the location of php-cgi.exe file.

Apr 28, 2011Hoan Huynh
How To Install PHP 5 on IIS 7 with FastCGIKeep Posting When You're On Vacation With WordPress Post TimeStamp
You Might Also Like:
  • My First WordPress Plugin
  • How To Change Default Home Page Of WordPress
  • WordPress View Large Image Without Leaving Current Page
  • Add WordPress Login Form On Sidebar Or Custom Page
  • Show Error Message On WordPress Custom Login Template Page
  • Sending Email With SMTP Authentication In WordPress
  • Add And Get Custom Field In WordPress
  • WordPress IIS: The page isn’t redirecting properly
  • Auto check and fix spelling, missed words, style, and grammar in WordPress
  • Auto Rotate Web Page Title With JavaScript
Hoan Huynh

Hoan Huynh is the founder and head of 4rapiddev.com. Reach him at [email protected]

11 years ago InternetHow To, Wordpress230
0
GooglePlus
0
Facebook
0
Twitter
0
Digg
0
Delicious
0
Stumbleupon
0
Linkedin
0
Pinterest
Most Viewed
PHP Download Image Or File From URL
24,451 views
Notepad Plus Plus Compare Plugin
How To Install Compare Text Plugin In Notepad Plus Plus
21,829 views
Microsoft SQL Server 2008 Attach Remove Log
Delete, Shrink, Eliminate Transaction Log .LDF File
17,646 views
JQuery Allow only numeric characters or only alphabet characters in textbox
14,984 views
C# Read Json From URL And Parse/Deserialize Json
11,710 views
4 Rapid Development is a central page that is targeted at newbie and professional programmers, database administrators, system admin, web masters and bloggers.
Recent Posts
  • Things to Learn about Installingderm Loan Type S
  • Online Photo Editor – Free Photoediting Software
  • A Guide to Finding the Best Paper Sellers
  • Photoediting in Home Isn’t Hard to Do!

  • Free Photo Editor Online
Categories
  • CSharp (45)
  • Facebook Graph API (19)
  • Google API (7)
  • Internet (87)
  • iPhone XCode (8)
  • Javascript (35)
  • Linux (27)
  • MySQL (16)
  • PHP (84)
  • Problem Issue Error (29)
  • Resources (32)
  • SQL Server (25)
  • Timeline (5)
  • Tips And Tricks (141)
  • Uncategorized (647)
Recommended
  • Custom Software Development Company
  • Online Useful Tools
  • Premium Themes
  • VPS
2014 © 4 Rapid Development