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

Lack of Interest xf_thread_redirect records, hard-coded links

Discussion in 'Closed Suggestions' started by Jake Bunce, Mar 8, 2012.

  1. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    Screen shot 2012-03-08 at 1.48.33 AM.png

    Redirect locations should be built at run time using the route handlers. Hard-coded links are bad.

    This creates a unique problem for my Route Changer addon which needs to change those "threads" links at run time... which it can't do if the handler is not called as is the case here.

    I can't imagine any other situation where this is a problem, but hard-coded links are still bad.
     
  2. Rob

    Rob Well-Known Member

    Wont clicking a link just redirect though? As long as there is a 301 is it that bad?
     
  3. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    Yes it will 301 redirect with my addon except in the case where you overwrite existing routes, such as with a swap of two existing routes:

    Screen shot 2012-03-14 at 4.04.36 AM.png

    The old "threads" route cannot be redirected here because it is being used for something else.

    It's a weird case, and one that is not likely to come up. But it's still a problem so I made a post about it.
     
  4. Rob

    Rob Well-Known Member

    On a side note, i've always thought that links in user generated content could be captured and inspected to see if they link to a node, thread, post, page etc and then they be substituted for something that is generated at run time. That way whenever the url schema changes the links in posts change too. Ok, maybe thats pie in the sky.
     

Share This Page