Forum Moderators: phranque
I want to move from Windows to Linux server. Should redirect every old .asp page to new .php page on Linux. I will preserve all URL intact (the same) except extension.
Pages are dynamic ie. page.asp?kat=23&lang=de to page.php?kat=23&lang=de
Anyone knows redirect mod rule for acheive this goal. Many old pages are indexed as .asp pages in Google.
I need to redirect each page click .asp going automatically to .php
I need also 301 redirect (permanent)
Thank you.
I will preserve all URL intact (the same) except extension.
Why not preserve all the URLs intact and KEEP the extension?
You can configure apache/php to parse .asp files even though they'll be written in PHP.
Moving every single page on your site, even if only from foo.asp to foo.php, is not a good idea unless it's absolutely necessary, and IMHO in your situation it isn't.
Good advice given here, no need to change the extensions if you don't want to yet. Here is a relative thread in PHP that discusses the same topic, just different extensions.
Do I have to change .html to .php? [webmasterworld.com]
Section global for suphp look like this (Apache2/php5):
#SuPhp
suPHP_Engine on
AddHandler x-httpd-php5 .php5
AddHandler x-httpd-php4 .php4
suPHP_AddHandler x-httpd-php5
suPHP_AddHandler x-httpd-php4
Do I need add .asp at the end of two lines AddHandler....?
Thanks?