interealm Posted August 28, 2007 Share Posted August 28, 2007 Hi there, I am a new to PHP and I need to convert an entire ASP site to PHP. That is fine but there is a particular ASP page that has been bookmarked by many people. I was wondering if it is possible to create a PHP file that redirects the users to the correct link but have the file saved with an ASP extension instead of PHP. More information: I have http://www.intelligencerealm.com/countries/local/system.asp in IIS on a Win/IIS server and now I want to move the page to http://www.intelligencerealm.com/aisystem/system.php on a site that runs entirely on linux/apache/php and have the old machine discarded. Is this possible? Any help would be appreciated. Thanks, Ovidiu Link to comment https://forums.phpfreaks.com/topic/67024-asp-php-page-bookmark/ Share on other sites More sharing options...
trq Posted August 28, 2007 Share Posted August 28, 2007 You can quite easily direct request to .asp files to .php by putting something like the following in your .htaccess file. RewriteEngine On RewriteBase / RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^([a-z0-9]+).asp$ $1.php [L] Link to comment https://forums.phpfreaks.com/topic/67024-asp-php-page-bookmark/#findComment-336184 Share on other sites More sharing options...
interealm Posted August 28, 2007 Author Share Posted August 28, 2007 Thanks a lot. Regards, Ovidiu Link to comment https://forums.phpfreaks.com/topic/67024-asp-php-page-bookmark/#findComment-336424 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.