At 10:21 03.03.2003, Cranky said: --------------------[snip]-------------------- >I have a website and all my files are *.php3 >I would like to change the extensions of all files to *.php > >So I would like to know if there is a way perhaps with a .htaccess file to >say that the file .php3 must be redirect to the same file but in *.php > >So when I try to access this page : >http://www.my-site.com/page.php3?param=value > >I will access this page : >http://www.my-site.com/page.php?param=value --------------------[snip]--------------------
If you have the ability to use mod-rewrite, you can do RewriteEngine On RewriteCond %{REQUEST_URI} ^.*\.php3.*$ [NC] RewriteRule ^(.*)\.php3(.*)$ $1.php$2 [L] This can be done either in the general configuration, within <VirtualHost>, or within <Directory>. I am using exactly this stuff to allow legacy links to a site that has been developed in Python (*.py) to access the same URLs as PHP files. -- >O Ernest E. Vogelsinger (\) ICQ #13394035 ^ http://www.vogelsinger.at/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php