48
devTea
5y

I saw someone handle redirect on every anchor link on server side. Yes, they handle onclick on serverside and then decide where to redirect. No they don’t use href or any sort that’s stated on the HTML. And this guy is my senior.

Comments
  • 1
  • 1
    WTF, how do you even do that ?
  • 1
    @muttley how he think that’s okay is beyond me
  • 1
    @devTea Thats it. Now i know why you left that job.
  • 14
    That guy is so far ahead, he looks at MVC patterns in the rearview mirror
  • 2
    should implement a whole rest API just to handle clicks, with a scheme like

    api/links/:link

    and the response contains the name of the page that should be rendered which you can then handle in the front end :D

    note: yes I am trolling
  • 1
    I used to call apis in core php code inside my laravel controller with curl
  • 1
    Bizarre... have you asked him why?
  • 1
    probably old and forgotten code
  • 1
    @localdam I’ve problems with him in the past. Not gonna bother handling his shit again.

    @achu he is 26 and it’s a new project now
  • 1
    This sounds like a simpleton predecessor of HATEOAS (Hypermedia As The Engine Of Application State) where the redirect links are part of the REST API response itself.
  • 1
    @noder this is on ASP.NET webforms
  • 1
    @devTea 🤦‍♂️🤦‍♂️🤦‍♂️🤦‍♂️🤦‍♂️
  • 1
    Howdy cowboy
  • 1
    @kgbemployee no the client doesn’t understand this kind of thing
  • 1
    Can’t trust anyone these days. Handle all the things server side....
Add Comment