in reply to perl file + .htaccess + mod rewrite

If you're using the CGI module, I think you're looking for the path_info function:
       path_info()
           Returns additional path information from the script
           URL.  E.G. fetching /cgi-bin/your_script/addi­
           tional/stuff will result in $query->path_info()
           returning "/additional/stuff".