• Quick (I hope) question:

    I have WordPress running on my computer (want to get new site running before posting replacing my current html site) but I can’t get “Pretty” permalinks to work (404 errors when I try to access any page other than the “index” page). The “Default” setting works just fine.

    When I get ready to post the WordPress version of my web site, I’d like to have the “Pretty” permalinks (month/day/year/sample-post). Will I have a problem? I want to keep a copy on my computer (for tweaking, etc.) but want both the web site and my “localhost” version to work.

    (If it matters, everything was installed on my computer via Microsoft Web Platform Installer, and everything appears to have installed correctly…)

Viewing 8 replies - 1 through 8 (of 8 total)
  • assuming you are using IIS on your local machine, you need to read this:

    http://codex.wordpress.org/Using_Permalinks#Permalinks_without_mod_rewrite

    When I get ready to post the WordPress version of my web site, I’d like to have the “Pretty” permalinks (month/day/year/sample-post). Will I have a problem?

    that depends. READ this:

    http://codex.wordpress.org/Using_Permalinks

    Your hosting environment is what you need to be concerned with – not WordPress.

    I want to keep a copy on my computer (for tweaking, etc.) but want both the web site and my “localhost” version to work.

    can you define what you mean by “work”, after youve read the links above 🙂

    Thread Starter awtj

    (@awtj)

    THANK YOU for the ultra fast reply! I was called away right after I posted my question, or I’d have been right back with you then.

    “Work” means that once I have everything set on my computer (localhost) that I can upload the files to my web site and everything works there, too. 🙂

    Then I can play / tweak / etc. on my computer to make things better as I learn more about WordPress, then uplaod any changes to the web site and it STILL works! 😉

    SO… What I’m getting from reading the two links above is:

    1 – I should make sure that my web hosting site is not Windows-based

    ** OR **

    Install Windows URL Rewrite Module on my web site

    ** AND **

    2 – I should install Windows URL Rewrite Module on MY computer (localhost) so that “Pretty” permalinks will work

    ** OR **

    I should not worry about it because when I upload the pages / categories / etc. they will all get the “Pretty” permalink URL as long as I enable it during the initial WordPress installation on my web host site?

    Thread Starter awtj

    (@awtj)

    OK… Folowing the directions, I have installed URL Rewrite Module 1.1 (using Microsoft Web Platform Installer). However…

    Once installed, open the web.config file in the WordPress folder and add the following rule to the system.webServer element . . .

    There is NO web.config file to edit anywhere in my computer.

    So… now what?

    I have a similar problem. I have a web.config, but it has almost nothing in it. It is in the directory above my wordpress install. I tried copying it to my /blog/ directory, but I still don’t have pretty permalinks.

    I tried just copying the rewrite block of text into the end of the web.config file because it has no system.webServer section. When that didn’t work I tried adding a <system.webServer></system.webServer> wrapper around all of that.

    My web host told me I have IIS 7 with URL Rewrite and FastCGI. At this point I don’t know what else to try.

    If you have IIS 7 and the URL rewrite module installed, to get wordpress to use pretty permalinks your web.config should look like this:

    <?xml version="1.0" encoding="UTF-8"?>
    <configuration>
      <system.webServer>
        <rewrite>
          <rules>
            <rule name="wordpress" patternSyntax="Wildcard">
              <match url="*" />
              <conditions>
                <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>

    That is exactly what my web.config file looks like in my /blog/ folder. I still don’t have pretty permalinks.

    I may be switching to Linux on my webserver because I am also having trouble with my RSS feeds and I’ve been reading wordpress works a bit better with Linux.

    Linux is certainly easier to setup with the .htaccess.

    For IIS if you have this as the web.config, have a permalink chosen other than default in the Admin Control Panel. It should work. You will need to make sure that your php is configured properly as well.

    If you are running PHP as a fast cgi module you need in your php.ini:
    cgi.force_redirect=0
    fastcgi.impersonate=1

    Hope this helps.

    1. I changed the permalink structure and it almost works. I made a test post and it has a pretty permalink, but even the new post doesn’t show up on my blog page (xxxxxx.com/blog). It shows up under ‘recent posts’ and when I click the link, it goes to it and has a pretty permalink. But now my main page shows no entries. Even the new one.

    2. I placed a php.ini file in the directory just above my blog with the two lines you mentioned, but I still have no posts on the main page, but the pretty permalinks are there.

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘“pretty” permalinks’ is closed to new replies.