tags:

views:

60

answers:

2

Hi,

I've got a really simple question. I want to redirect all requests to http://localhost/home/ and http://localhost/home to home.php

My .htaccess file contains:

RewriteRule ^home/$ home.php [L]

which only works for http://localhost/home/

How can I make it work without the /in the url too? Is it possible to do it in one line, as opposed to two separate lines such as:

RewriteRule ^home/$ home.php
RewriteRule ^home$ home.php

Thanks :)

+2  A: 
RewriteRule ^home/?$ home.php
Adam Backstrom
+3  A: 
RewriteRule ^home/?$ home.php [L]
Ignacio Vazquez-Abrams