.htaccess - redirect all pages with htaccess -
i've been looking find solution problem believe i'm not asking right question i'll explain in detail here.
i built new html site , want redirect old domain php site new domain going html site. url structure same file format changed.
i need .htaccess code redirects pages old domain pages of new domain.
for example: oldsite.com/contact.php ===> newsite.com/contact.html
any ideas? thanks
try adding rule htaccess file in oldsite.com's document root:
rewriteengine on rewritecond %{http_host} oldsite\.com$ [nc] rewriterule ^(.*)\.php$ http://newsite.com/$1.html [l,r=301]
Comments
Post a Comment