• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.
  • This forum has been archived. New threads and replies may not be made. All add-ons/resources that are active should be migrated to the Resource Manager. See this thread for more information.

vBulletin 4.x URL Redirection

Status
Not open for further replies.

Jaxel

Well-known member
#42
Hey Darkimmortal... I just encountered my first error with this mod...

I had VB4 installed in the ROOT, with mod rewrite URLs.
I installed XenForo in the ROOT, with mod rewrite URLs.
I installed this mod using all FOUR steps of the mod rewrite URLs section.
I did not do any of the additional "change of directory" steps.

Up until now it has worked great. However, I have since encountered a few problems that only occur when this mod is enabled...

This thread:
http://www.8wayrun.com/threads/30-01-2011-france-streaming-gcc4.6601/

With the mod enabled, can not be replied to. If you click "More Options" on the reply form, instead of bringing you to /add-reply, it will bring you to:
http://www.8wayrun.com/threads/general-strategy.20/

With this thread: http://www.8wayrun.com/threads/10-chicago-casual-play-vids.6566/
It will take you to: http://www.8wayrun.com/threads/arizona-az-fighters-if-there-are-any.9/

I have fixed this issue by disabling this mod for now.
 

Luke F

Well-known member
#43
Hey Darkimmortal... I just encountered my first error with this mod...

I had VB4 installed in the ROOT, with mod rewrite URLs.
I installed XenForo in the ROOT, with mod rewrite URLs.
I installed this mod using all FOUR steps of the mod rewrite URLs section.
I did not do any of the additional "change of directory" steps.

Up until now it has worked great. However, I have since encountered a few problems that only occur when this mod is enabled...

This thread:
http://www.8wayrun.com/threads/30-01-2011-france-streaming-gcc4.6601/

With the mod enabled, can not be replied to. If you click "More Options" on the reply form, instead of bringing you to /add-reply, it will bring you to:
http://www.8wayrun.com/threads/general-strategy.20/

With this thread: http://www.8wayrun.com/threads/10-chicago-casual-play-vids.6566/
It will take you to: http://www.8wayrun.com/threads/arizona-az-fighters-if-there-are-any.9/

I have fixed this issue by disabling this mod for now.
I can't reproduce the issue on my end, but it's probably a trigger happy regex in Route/Prefix/Threads.php. If you can't fix the issue there then you could just fall back to using the original mod_rewrite rules, which should still work alongside XenForo.
 

gldtn

Well-known member
#44
Darkimmortal,

Ok I uploaded the content of standard-basic-advanced/upload to the forum root and added
RewriteRule ^/old-dir/showthread.php /new-dir/showthread.php RewriteRule ^/old-dir/forumdisplay.php /new-dir/forumdisplay.php

to my .htacces file inside my forum root and I even tried adding it to my .htaccess inside my root folder
by it redirects me to my main xenforo page itead of the thread

I installed xenforo on a dnew directory
 

Luke F

Well-known member
#45
Darkimmortal,

Ok I uploaded the content of standard-basic-advanced/upload to the forum root and added
RewriteRule ^/old-dir/showthread.php /new-dir/showthread.php RewriteRule ^/old-dir/forumdisplay.php /new-dir/forumdisplay.php

to my .htacces file inside my forum root and I even tried adding it to my .htaccess inside my root folder
by it redirects me to my main xenforo page itead of the thread

I installed xenforo on a dnew directory
Are you sure you need those rewrite rules? Try without them
 

gldtn

Well-known member
#46
Are you sure you need those rewrite rules? Try without them
did not work..

Here is my .htaccess from my root folder

Code:
RewriteEngine On

IndexIgnore .htaccess */.??* *~ *# */HEADER* */README* */_vti*

<Limit GET POST>
order deny,allow
deny from all
allow from all
</Limit>
<Limit PUT DELETE>
order deny,allow
deny from all
</Limit>
AuthName www.domain.org
AuthUserFile /home/cogumelo/public_html/_vti_pvt/service.pwd
AuthGroupFile /home/cogumelo/public_html/_vti_pvt/service.grp

RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^http://artigos.domain.org/.*$      [NC]
RewriteCond %{HTTP_REFERER} !^http://artigos.domain.org$      [NC]
RewriteCond %{HTTP_REFERER} !^http://biblioteca.domain.org/.*$      [NC]
RewriteCond %{HTTP_REFERER} !^http://biblioteca.domain.org$      [NC]
RewriteCond %{HTTP_REFERER} !^http://domain.org/.*$      [NC]
RewriteCond %{HTTP_REFERER} !^http://domain.org$      [NC]
RewriteCond %{HTTP_REFERER} !^http://galeria.domain.org/.*$      [NC]
RewriteCond %{HTTP_REFERER} !^http://galeria.domain.org$      [NC]
RewriteCond %{HTTP_REFERER} !^http://www.artigos.domain.org/.*$      [NC]
RewriteCond %{HTTP_REFERER} !^http://www.artigos.domain.org$      [NC]
RewriteCond %{HTTP_REFERER} !^http://www.biblioteca.domain.org/.*$      [NC]
RewriteCond %{HTTP_REFERER} !^http://www.biblioteca.domain.org$      [NC]
RewriteCond %{HTTP_REFERER} !^http://www.domain.org/.*$      [NC]
RewriteCond %{HTTP_REFERER} !^http://www.domain.org$      [NC]
RewriteCond %{HTTP_REFERER} !^http://www.forum.domain.org/.*$      [NC]
RewriteCond %{HTTP_REFERER} !^http://www.forum.domain.org$      [NC]
RewriteCond %{HTTP_REFERER} !^http://www.galeria.domain.org/.*$      [NC]
RewriteCond %{HTTP_REFERER} !^http://www.galeria.domain.org$      [NC]

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d

Options All
And from the xenforo root folder

Code:
<IfModule mod_rewrite.c>
    RewriteEngine On

    #    If you are having problems with the rewrite rules, remove the "#" from the
    #    line that begins "RewriteBase" below. You will also have to change the path
    #    of the rewrite to reflect the path to your XenForo installation.
    #RewriteBase /xenforo

    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -l [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule ^.*$ - [NC,L]
    RewriteRule ^(data|js|styles|install) - [NC,L]
    RewriteRule ^.*$ index.php [NC,L]
  
</IfModule>
 

Luke F

Well-known member
#47
did not work..
-snip-
Can you give me some example URLs? Also try adding these rewrites to the root .htaccess:

Code:
RewriteRule ^/forum/showthread.php /xenforo/showthread.php
RewriteRule ^/forum/forumdisplay.php /xenforo/forumdisplay.php
(Replace 'forum' with the directory vB4 was installed in)


Also make sure you uploaded the contents of 'standard-basic-advanced/upload' to '/xenforo' rather than '/'.
 

gldtn

Well-known member
#48
It is still doing like mentioned on the other thread, the showthread.php?t=THREAD_ID redirects fine, but showthread.php?THREAD_ID-thread-title does not :/
 

Ray

Active member
#53
Why is it that whenever I check the server status header, I get a " Wrong service type or malformed URL " ?

Shouldn't I be seeing the 200 OK status code?
I see that the Redirect Target shows: /1/index.php?threads/5220/
rather than the full url.

The redirection does work but the server response is what's worrying me.

Thanks
 

Jaxel

Well-known member
#54
I can't reproduce the issue on my end, but it's probably a trigger happy regex in Route/Prefix/Threads.php. If you can't fix the issue there then you could just fall back to using the original mod_rewrite rules, which should still work alongside XenForo.
what are these original mod_rewrite rules?


BTW, I've determined that as this mod stands now, it is unusable. The system uses the Import Log to handle the maps from old IDs to new IDs. The problem is that the import log is volatile; it gets wiped whenever a new import is started. So I may import all my forum information one time, and that fills it up with the relevant id maps. But if I do another import, such as from another forum, all the old id maps get wiped out.
 

Luke F

Well-known member
#55
what are these original mod_rewrite rules?
Just grab any set of vBulletin 4 rewrite rules, such as the ones included with it

BTW, I've determined that as this mod stands now, it is unusable. The system uses the Import Log to handle the maps from old IDs to new IDs. The problem is that the import log is volatile; it gets wiped whenever a new import is started. So I may import all my forum information one time, and that fills it up with the relevant id maps. But if I do another import, such as from another forum, all the old id maps get wiped out.
Kier's vB3 redirection script behaves the same way (this is just it with some modification) - importing is designed to only happen once so it is working as intended.
 

Veer

Well-known member
#56
Hey Darkimmortal... I just encountered my first error with this mod...

I had VB4 installed in the ROOT, with mod rewrite URLs.
I installed XenForo in the ROOT, with mod rewrite URLs.
I installed this mod using all FOUR steps of the mod rewrite URLs section.
I did not do any of the additional "change of directory" steps.

Up until now it has worked great. However, I have since encountered a few problems that only occur when this mod is enabled...

This thread:
http://www.8wayrun.com/threads/30-01-2011-france-streaming-gcc4.6601/

With the mod enabled, can not be replied to. If you click "More Options" on the reply form, instead of bringing you to /add-reply, it will bring you to:
http://www.8wayrun.com/threads/general-strategy.20/

With this thread: http://www.8wayrun.com/threads/10-chicago-casual-play-vids.6566/
It will take you to: http://www.8wayrun.com/threads/arizona-az-fighters-if-there-are-any.9/

I have fixed this issue by disabling this mod for now.
Jaxel, have you found a fix, if so then please guide me to it as I'm having same problem.
OR
Dark, may be you troubleshoot this?

Thanks.
 

Jaxel

Well-known member
#57
Jaxel, have you found a fix, if so then please guide me to it as I'm having same problem.
OR
Dark, may be you troubleshoot this?

Thanks.
Nope... I've just stopped using this mod all together. Many of my threads have numbers in the titles, and the regex conflicts with that.
 

Janmaat

Active member
#58
I have no clue what I shall do here :(

I have my vB4 test board installed on http: //testboard.mysite. com
And I have my XF test board installed on http: //xf.mysite. com

I have successfully imported the vB4 into XF, but I have no clue how to make the internal links like http: //testboard.mysite. com/blabla redirect to http: //xf.mysite. com/blabla
 
Status
Not open for further replies.