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

Need a little mod rewrite help

Okay here is the dealio.... The forum has been around for about 18 years total and I have moved from several software packages to Xenforo where I am now. I have a way to rectify my attachment issues long term but need to be able to get a mod rewrite working for a particular issue.

I have embedded in some image tags the following URL structure:

1) http://domain.com/iB_html/uploads/image.jpg

My forum is located here now:

2) http://domain.com/forum/

Here is my current .htaccess file and I also have the VB rewrites scripts running too!

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTP_HOST} ^domain.com [nc]
RewriteRule ^(.*)$ http://www.domain.com/forum/$1 [R=301,L]
RewriteRule ^[^/]+/([0-9]+)-[^\./]+\.html$ /forum/threads/$1/ [R=301,L]
RewriteBase /forum
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -l [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^.*$ - [NC,L]
RewriteRule ^(data/|js/|styles/|install/|favicon\.ico|crossdomain\.xml|r obots\.txt) - [NC,L]
RewriteRule ^.*$ index.php [NC,L]

I need to get the links on the first line working so that I can import and attach the images to the xenforo standard data structure. I can do the second part manually, I just need a rewrite that allows me to type the old url in and have it work. I need the script to see the old URL with iB_html request and redirect it to where the images are currently located...