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

Redirection Scripts for vBulletin 3.x - htaccess file?

Discussion in 'Installation, Upgrade, and Import Support' started by Netsultants, Dec 8, 2010.

  1. Netsultants

    Netsultants Active Member

  2. Netsultants

    Netsultants Active Member

    I need some help here...... Is this mike on? "Testing... testing"
     
  3. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    I played with those redirection scripts once before. I had trouble getting the scripts to change directories. But they work great when they reside in the same directory as xenForo.

    I would do this:

    1) Upload the redirect scripts to the same directory as xenForo.

    2) Put a .htaccess file in the old vB directory which redirects to the new xenForo directory:

    Code:
    Redirect 301 /forums /new_forum
    
    This should work for you. Let me know if it doesn't.
     
  4. Netsultants

    Netsultants Active Member

    Ok, so I put the scripts in the wrong dir?

    The thread says "All you need to do is unzip these files and place them in the directory within which the vBulletin files with the corresponding names would be located."

    Also, what should the htaccess file look like? - Thanks!
     
  5. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    You can probably do it with just the redirect scripts. But I failed to get them to change directories in my testing. So my instructions above setup a double redirect. The .htaccess file changes directories. And once there, the redirect scripts map the old vB locations to the new xenForo locations.
     
  6. Netsultants

    Netsultants Active Member

    The error I get when going into a VB link with just the redirect scripts is "No such file or directory" ....../forums/library/XenForo/Autoloader.php

    That makes sense because the file is /forums/library/XenForo/Autoloader.php and /forums is the vb folder and it doesn't exist.

    It should be looking for it here: /New_forums/library/XenForo/Autoloader.php I would think.
     
  7. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    That's the problem I had when trying to get the redirect scripts to work outside of the xenForo directory. I tried changing
    $fileDir
    in the script, and I also tried manually specifying all paths in the script, but it still didn't work. I also tried chdir(). Maybe I was doing something wrong. But it should work if you leave the redirect scripts in the xenForo directory and then use the .htaccess file to handle changing directories.
     
    Netsultants likes this.
  8. Netsultants

    Netsultants Active Member

    Jake, you're probably right. I'd really like to get this working the way it was intended or at least figure out what the problem is.

    I don't think we are the only ones with this problem.
     
  9. Netsultants

    Netsultants Active Member

Share This Page