What's new
AMJ Bulletin Board

[INFO] Changing domain name using .htaccess redirect

elboriyorker

Administrator
Staff member
OG Member
These instructions are for those who want to change their forum domain name and have many internal and external links you want to redirect.

For example you have the following:

https://olddomain.com/

and you want to redirect to:

https://newdomain.com/forums/

Create a .htaccess file in the olddomain.com directory and add the following code:

Code:
RewriteEngine On
RewriteRule ^(.*)threads/(.*)/?$ https://newdomain.com/forums/threads/$2 [R=301,L,NC,NE]



These instructions are for those who want to change their forum domain name and have many internal and external links you want to redirect.

For example you have the following:

https://olddomain.com/

and you want to redirect to:

https://newdomain.com/forums/

Create a .htaccess file in the olddomain.com directory and add the following code:

Code:
RewriteEngine On
RewriteRule ^(.*)threads/(.*)/?$ https://newdomain.com/forums/threads/$2 [R=301,L,NC,NE]

For example you have the following:

https://olddomain.com/forums/

and you want to redirect to:

https://newdomain.com/

Create a .htaccess file in the olddomain.com directory and add the following code:

Code:
RewriteEngine On
RewriteRule ^(.*)threads/(.*)/?$ https://newdomain.com/threads/$2 [R=301,L,NC,NE]
 
Back
Top