XF 2.1 XF301VB: vB2 links not redirected

thomas1

Well-known member
Surprisingly, we still get a lot of requests for links in vB2 formats, such as

https://site.com/forum/showthread.php?s=&threadid=6126

https://site.com/forum/showthread.php?s=&postid=55416

Unfortunately, calls using threadid and postid are not redirected by the official XF301VB script.

We'd appreciate any suggestions on how to effectively redirect those, too. :)
 
We opened a ticket with support and they suggested the following:

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

It works on our site. :)
 
That would partially work, but not always.

For example the following URL would most likely fail:
https://site.com/forum/showthread.php?foothreadid=0&threadid=6126
 
Back
Top Bottom