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

XF 1.2 Route Filters & Duplicate URLs

TheBigK

Well-known member
#1
We recently added a route filter to form new URLs - /resources/ was changed to /downloads/ . I checked that Google is reporting duplicate URLs. Because the resources which were linked from the forum posts that had /resources/ in the URL are still intact. That is, even with the router filter in place, if I directly type /resources/ , the page loads fine. Which means there are two URLs on the site that have exactly the same content.

Is there any way to fix this?
 

Mike

XenForo developer
Staff member
#2
Routes will canonicalize automatically if the controller in question calls it -- it's generally only called when there's content that might change in the URL (like thread titles).

I suppose for your usage, you could do a .htaccess redirect:
Code:
RedirectMatch 301 ^/resources/?$ http://example.com/downloads/