URL Rewrite for Localhost

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • adamjblakey
    New Member
    • Jan 2008
    • 133

    URL Rewrite for Localhost

    Hi,

    I am working off local host and i want to use htaccess but i am unsure on the code that i would need.

    This is my normal re-write rule for a domain like e.g http://www.bob.com/info..php

    Code:
    RewriteEngine On
    RewriteRule ^([a-zA-Z0-9-_]+)\.html$ info.php?title=$1
    But on local host the url is: http://localhost/xampp/websites/site1/info.php so what would i put in the htaccess file for this?

    I was thinking something like this but it does not work;

    Code:
    RewriteEngine On
    RewriteRule ^([a-zA-Z0-9-_]+)/([a-zA-Z0-9-_]+)/([a-zA-Z0-9-_]+)/([a-zA-Z0-9-_]+)/([a-zA-Z0-9-_]+)\.html$ info.php?cat=$1&item=$2&other_item=$3&title=$4&others_items=$5
    Cheers,
    Adam
Working...