Question

I picked up a new-to-me client who had a site built in ASP.net (which I do not host).

I converted the site to PHP, which worked fine.

I want to set up redirects for all the pages he had in the old site (it was a small site, so there was only 8 pages).

As an example, the ASP.net url for the Contact page was www.domain.com/Contact - it is now www.domain.com/Contact.php (and so on).

For 301 redirects from one PHP page to another I normally use the .htaccess file:

Options +FollowSymlinks
RewriteEngine on
#custom redirects
rewriterule OldPage.php http://www.domain.com/NewPage.php [R=301,L]
#end custom redirects

What can I do to redirect these ASP.net pages to the new PHP pages?

They are all static pages with no dynamic content.

Was it helpful?

Solution

Not exactly what you asked for, but if you turn Multiviews on then Apache will look for Contact.* and find your .php file.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top