XF 1.2 redirect rule messes up only a few URL

wtgw

Member
My .htaccess is messing up a few select URL in an add-on but since the redirect rule was for xenforo, I think it's somehow related to this.

RewriteRule ^[^/]+/.+-([0-9]+)/$ index.php?threads/$1/ [R=301,L]

I don't remember exactly what this even does.

All my xencarta URL were fine but I recently upgraded to xenforo 1.2.4 and noticed that a few links in xencarta now returned the wrong URL. Removing this rewriterule fixed it but I haven't a clue why. I used to have vb3.8 and vbseo.

As an example, the wrong returned URL looks like this: home/ my vps account name/ and the rest as shown below with either /1, 2, 3, etc. Any idea why this is happening? This .htaccess is in my forum root.

http://www.example.com/home/vpsaccountname/public_html/index.php?threads/3/
 
What was the original URL?

However, since you're using a 301 redirect with that rule, you may want to simply use the full URL as the redirect target.
 
the original URL was www.example.com/wiki/wiki-article-title/

Something is definitely weird here. I edited an article with my admin account. It saved and I can view it only with that account. When viewing it with any other account, even another admin account, it goes back to the wrong redirected URL with "The requested page could not be found". Removing the redirect rule let me view those pages which weren't working but now I'm seeing this weird response.

I think this happened after I upgraded to 1.2.4. I did apply that server fix for tapatalk to application.php. Is there anything specific to xenforo which would cause this behavior? Something like a session ID which only allows that user to view something that they edited? Before I removed the redirect rule, the only way I could access the article was by going to www.example.com/wiki/wiki-article-title/edit/
 
I still don't know what happened but I rewrote the affected links. I had to name it something different because it kept showing the same error if I deleted it and renamed it with the same name.
 
Back
Top Bottom