WordPress Permalinks web.config File Creation when there is a Permissions Error

When attempting to enable permalinks in Wordprss, you may come across the following message at the top of the settings-permalinks page after selecting a common settings style:

You should update your web.config now

Followed by this message below the ‘Save Changes’ button:

If the root directory of your site were writable, we could do this automatically, but it isn’t so this is the url rewrite rule you should have in your web.config file. Create a new file, called web.config in the root directory of your site. Click in the field and press CTRL + a to select all. Then insert this code into the web.config file.

All this means is that the root directory for your site is not writable, and WordPress has just attempted unsuccessfully to create the new file called web.config. This is a good thing, and means that the root folder permissions on your server are at a more secure setting.

To get permalinks working, follow the steps outlined above or:

  1. Open notepad (windows)
  2. Copy and paste the code block from WordPress into the new notepad document
  3. Click File -> Save
  4. Select ‘All Files (*.*) from the Save as type drop-down menu
  5. Type in ‘web.config’ and remove the .txt
  6. FTP this file to the root folder

One last thing, click on ‘Save Changes’ in WordPress after selecting the type of permalinks you want. A Second message will appear:

If your web.config file were writable, we could do this automatically, but it isn’t so this is the url rewrite rule you should have in your web.config file. Click in the field and press CTRL + a to select all. Then insert this rule inside of the /<configuration>/<system.webServer>/<rewrite>/<rules> element in web.config file.

Ignore this message, permalinks will already be working. Visit you blog and click on a post heading to see the permalinks in action!

This is current as of WordPress 3.3.1.

One thought on “WordPress Permalinks web.config File Creation when there is a Permissions Error

Leave a Reply to anthony Cancel reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>