Forums

How to change permalinks under WAMP. (12 posts)

  1. IanHobson
    Member
    Posted 2 years ago #

    I'm, running Windows XP and WAMP onelick, and trying to set up WP as a CMS, so I can create a new theme and site.

    I installed WordPress to / and it worked just fine "out of the box".

    Now I need to alter the permalinks so that pages have a SEO URL - e.g pages are http://example.com/slug and posts are http://example.com/blog/title.

    I altered the permalinks, and even with provided options (other that default) I get "page not found errors for every page, except the home and admin pages.

    .htaccess is writable, and mod rewrite is on.

    How can I change the permalinks to a SEO friendly style?

    Ian

  2. MichaelH
    Volunteer
    Posted 2 years ago #

    and mod rewrite is on.

    Makes me wonder if that is true?

  3. Samuel B
    moderator
    Posted 2 years ago #

    If you want to use permalinks, you will need to make a change inside another file:
    Click the Start button, followed by My Computer > Main drive > Xampplite > apache > Conf and find the file httpd.conf. Open that in a text editor. Use the search facility in the editor to find "rewrite". The line you need looks like this:

    #LoadModule rewrite_module modules/mod_rewrite.so

    You need to take away the hash sign so it looks like this

    LoadModule rewrite_module modules/mod_rewrite.so

    Now just save the file.

    ref
    http://www.tamba2.org.uk/wordpress/xampp/

  4. IanHobson
    Member
    Posted 2 years ago #

    Thanks for the replies guys. Sadly they didn't help.

    As already stated, mod-rewrite is both enabled and on, and I am using WAMP One click installer not XAMPP (same line in http.conf).

    This is the virtual host definition.

    <VirtualHost *:80>
       ServerName  chocolate.leda.hcs
       ServerAdmin ian@deleted
       DocumentRoot "D:\GitRepositories\Carrie"
    	RewriteEngine On
    	<Directory "D:\GitRepositories\Carrie">
    		Options Indexes
    		Order allow,deny
    		Allow from all
    	</Directory>
    </VirtualHost>

    The .htaccess file is

    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>
    
    # END WordPress

    Every page except the Home" page gives me a reply such as

    The requested URL /about/ was not found on this server.

    Unless I have the default permalink set. Then things work correctly.

    So what is going wrong? Ideas anyone?

    Ian

    p.s. I have removed and re-installed wordpress from a fresh download, just to remove the possibility of a corruption.

  5. Samuel B
    moderator
    Posted 2 years ago #

    honestly I have never got wamp to work right out of the box
    xampp on the other hand works every time
    sorry not more help

  6. MichaelH
    Volunteer
    Posted 2 years ago #

    What happens if you rename your .htaccess file?

  7. marcvdwurff
    Member
    Posted 2 years ago #

    Thanks samboll, this works fine for me on clean install of WAMPserver 2.0 on Windows XP (running standalone on localhost).

  8. room339
    Member
    Posted 2 years ago #

    In WAMP you need to turn on the rewrite_module. To do this click on the WAMP icon in your task bar and navigate to: Apache>Apache modules> Scroll down to rewrite_module and click it. Once you do this your pages should work immediately.

  9. alamster
    Member
    Posted 2 years ago #

    I ever face that problem and my solution :

    Find these lines (in httpd.conf) :

    #LoadModule rewrite_module modules/mod_rewrite.so

    remove # sign

    and this line

    <Directory />
    Options FollowSymLinks
    AllowOverride None
    Order deny,allow
    Deny from all
    </Directory>

    change into this :

    <Directory />
    Options FollowSymLinks
    AllowOverride FileInfo Options
    Order deny,allow
    Deny from all
    </Directory>

    Save and Restart apache followed by retest your permalink.

    ( I take it from my blog post that utilize xampp but I think it's not different in wamp).

  10. matphoto
    Member
    Posted 2 years ago #

    @room339

    Thanks! That worked perfectly.

  11. vinnyred
    Member
    Posted 1 year ago #

    @room339 - Your solution was perfect and within seconds the permalinks were prettier than a sunrise in the mountains :-)

    Wamp with wordpress installed locally looks great. No more FTP(ing) yourself senseless!

  12. nathan_v
    Member
    Posted 1 year ago #

    @room339 Thank you!! it works great :-)

Topic Closed

This topic has been closed to new replies.

About this Topic