• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Switching domains, need help...

JABRONI

Well-known member
#1
How do I transfer all my Xenforo forum to my new domain?

Do I just copy over the Xenforo sub folder to the new directory and import the SQL into a new database or is there a different way to do this?
 

kkm323

Well-known member
#2
yes, also don't forget to change the config.php file if needed. The main thing you should remember to write redirect lines in .htaccess file so you don't loss traffic.

if i can remember this is the code line i used to redirect my vb forum from site.com/vb directory to the home directory
Code:
RewriteEngine On
RewriteBase /
RewriteRule ^vb/(.*)$ /$1 [R=301,NC,L]
so you probably need to add this instead
RewriteRule ^vb/(.*)$ newdomain.com/$1 [R=301,NC,L]
-----------------------------------------------------------------------------------------------------------
since I used so many methods of different url in the sh**y software call vb
so i had all this codes in my htaccess

Code:
RewriteRule vb/forum.php http://www.newdomain.com/index.php [L,R=301]
RewriteRule vb/private.php http://www.newdomain.com/conversations [L,R=301]
RewriteRule vb/t([0-9]+) http://www.newdomain.com/showthread.php?t=$1 [L,R=301]
RewriteRule vb/users/([0-9]+) http://www.newdomain.com/member.php?u=$1 [L,R=301]
 

JABRONI

Well-known member
#6
Code:
RewriteEngine On
RewriteBase /
RewriteRule ^forums/(.*)$ bfghq.com/$1 [R=301,NC,L]
so that's what my htaccess needs?
 

kkm323

Well-known member
#7
Code:
RewriteEngine On
RewriteBase /
RewriteRule ^forums/(.*)$ bfghq.com/$1 [R=301,NC,L]
so that's what my htaccess needs?
Yes, .htaccess file is tricky and can be very useful. The .htaccess file need to be placed in the root of the old domain.
If you need any other help just ask and I would gladly help you.
 

Jake Bunce

XenForo moderator
Staff member
#11
If the two sites are on separate servers then you need to do a full move which is a backup + restore from the old server to the new one:

http://xenforo.com/community/threads/how-to-backup-and-restore-your-forum.7213/

If they are on the same server then you don't need to do a full server move. Just copy the forum files to the new domain and leave the library/config.php file pointing to the same database. Then update the board URL in the Admin CP:

Admin CP -> Home -> Options -> Basic Board Information -> Board URL

In either case you will probably want to redirect old traffic to the new URL which is what kkm323 is talking about.