Current I just finished migrating a WordPress site with the url www.boingnet.com/purl/ for the WordPress install. After migrating to a new server and changing the url to www.boingnet.com I am looking for a way to redirect all traffic from the old site to the new site and keep all digital assets.
http://www.boingnet.com/purl/pricing/
would go to....
Put this code in your .htaccess
under DOCUMENT_ROOT
directory:
Options +FollowSymLinks -MultiViews
# Turn mod_rewrite on
RewriteEngine On
RewriteBase /
RewriteCond %{HTTP_HOST} ^www\.boingnet\.com$ [NC]
RewriteRule ^purl/(.*)$ /$1 [L,R=301,NC]
RewriteRule ^purl/(.*) /$1 [R,L]
Should do the trick.
Create .htaccess
file in "pricing" folder , it contains those lines:
RewriteEngine on
RewriteRule (.*)$ /purl/$1 [R=301,L]