XF 1.5 Best vB 4 to XF redirection method?

XYZ500

Active member
After the import, what is the best way to go about redirecting old links to XF in a way that you don't lose even one bit of SEO rankings? Using a redirection script add-on or coding .htaccess? If it's the former, please recommend the best redirection script add-on. If it's the latter, please recommend someone who can code the .htaccess file. It is of utmost importance that we don't lose even a single bit of search engines rankings.
 
The scripts are generally only required if you did not retain IDs.

If you retained IDs you can just use rewrite rules in .htaccess.

Neither method is better or worse as far as SEO is concerned.
 
Any guide available to writing these rules?

Heres the generics which will cover most things with some minor changes.


Code:
RewriteEngine On
#attachments
RewriteCond %{QUERY_STRING} attachmentid=([0-9]+)(&|$)
RewriteRule attachment\.php$ http://yoursite.com/attachments/%1? [R=301,L]

#forums
RewriteCond %{QUERY_STRING} f=([0-9]+)(&|$)
RewriteRule forumdisplay\.php$ http://yoursite.com/forums/%1? [R=301,L]

#users
RewriteCond %{QUERY_STRING} u=([0-9]+)(&|$)
RewriteRule member\.php$ http://yoursite.com/members/%1? [R=301,L]

#threads
RewriteCond %{QUERY_STRING} t=([0-9]+)(&|$)
RewriteRule printthread\.php$ http://yoursite.com/threads/%1? [R=301,L]

#posts
RewriteCond %{QUERY_STRING} p=([0-9]+)(&|$)
RewriteRule showpost\.php$ http://yoursite.com/posts/%1? [R=301,L]


#archives
RewriteRule archive/index\.php/t-([0-9]+)\.html$ http://yoursite.com/threads/$1 [R=301,L]
RewriteRule archive/index\.php/f-([0-9]+)\.html$ http://yoursite.com/forums/$1 [R=301,L]
RewriteRule ^archive/index\.php/t-([0-9]+)-p-([0-9]+)\.html$ forums/threads/$1/page-$2 [R=301,L]
 
Heres the generics which will cover most things with some minor changes.


Code:
RewriteEngine On
#attachments
RewriteCond %{QUERY_STRING} attachmentid=([0-9]+)(&|$)
RewriteRule attachment\.php$ http://yoursite.com/attachments/%1? [R=301,L]

#forums
RewriteCond %{QUERY_STRING} f=([0-9]+)(&|$)
RewriteRule forumdisplay\.php$ http://yoursite.com/forums/%1? [R=301,L]

#users
RewriteCond %{QUERY_STRING} u=([0-9]+)(&|$)
RewriteRule member\.php$ http://yoursite.com/members/%1? [R=301,L]

#threads
RewriteCond %{QUERY_STRING} t=([0-9]+)(&|$)
RewriteRule printthread\.php$ http://yoursite.com/threads/%1? [R=301,L]

#posts
RewriteCond %{QUERY_STRING} p=([0-9]+)(&|$)
RewriteRule showpost\.php$ http://yoursite.com/posts/%1? [R=301,L]


#archives
RewriteRule archive/index\.php/t-([0-9]+)\.html$ http://yoursite.com/threads/$1 [R=301,L]
RewriteRule archive/index\.php/f-([0-9]+)\.html$ http://yoursite.com/forums/$1 [R=301,L]
RewriteRule ^archive/index\.php/t-([0-9]+)-p-([0-9]+)\.html$ forums/threads/$1/page-$2 [R=301,L]

Thank you very much for this! By minor changes, do you only mean replacing the URL or something else too?

Replace the URL (it is https btw, does it make a difference?) and paste this in the .htaccess file and I'm good to go. Is that right?
 
Yup.

This assumes you are using the default URL format, and didnt set advanced urls or similar.

No advanced URLs are being used to my knowledge.
We're using vBA Advanced home page (works similar to Brogan's CTA Home Page and Widget Framework). The link format is as follows:

Home page = site.com/index.php or site.com
Forums = site.com/forum.php
Threads = site.com/showthread.php/235216 --> these numbers denoting thread ID.
Members profile = site.com/member.php/115026 --> member ID.

Is this the default URL format?
 
Ah, no.

Heres one which would work for threads in that format.

Code:
RewriteRule ^showthread\.php/([0-9]+) http://yoursite.com/threads/$1 [R=301,L]
 
Back
Top Bottom