url重写php内部服务器错误

i have a project runs from localhost i am using wamp local server to run my project. like localhost/re re is my project folder how can write in url rewriting using .htaccess ,
i tried but it throws an error

here is my .htaccess

RewriteEngine On    # Turn on the rewriting engine
RewriteRule    ^localhost/re/?$    refer.php    [NC,L]    # Handle requests for "re"

and when i run as localhost/re

error is

Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.

so how can i do it. Thanks in advance

Amit

You can do this using DirectoryIndex

RewriteEngine On
RewriteBase /re/

DirectoryIndex refer.php

now your default file is refer.php