37
woops
6y

Ahem ahem.
*clears throat*

Front end bois, listen that carefully.
YOU DONT FUCKIN TELL THE BACKEND HOW TO ACCEPT REQUESTS.

Backend creates the fuckin methods, the parameters and the responses, AND YOU FUCKIN ADAPT TO IT.

This guy at my work, we are both from Uni but i picked backend because i suck at frontend and i like using backend languages, sends me a message and tells me he can't make the project work.

At this time i have almost finished my part, i have made the method, have checked that they work, and i closed the work computer.

And now he tells me he wants to make a GET request instead of POST. LISTEN HERE MOTHERFUCKER. The methods are ready, adapt to them and shut the fuck up.

And before you tell me some methods don't work, make fuckin sure your part is correct because if i boot up the work laptop again to check why the method you have told me doesn't work, and it still does the job it was intented to do but you can't fix your part, i will fuckin cut your throat.

Sucker.
I do my part, and have to study for uni exams, since you don't have to because you have passed them, do your self a favor and fuckin learn to do things.

It's not my fault that i got experience on my own while you were just only doing our uni retarded projects and didn't bother to learn anything on your own.

I don't mean by any needs that i'm better than you but fuckin accept that i have learned something else that you have not and i would like to share the knowledge with you since you didn't bother.

Comments
  • 3
    @1989 i do, the front end guy doesn't want to understand it
  • 5
    @woops do you understand that POST requests with a body are impossible to make in frameworks like Ajax? Maybe your ignorance is a bit higher than that of your fellow student
  • 38
    Sorry, I don't GET this POST
    ...

    I'll show myself out
  • 4
    @ruhe One of us doesn't understand what you're saying. You can POST via ajax.
  • 0
    @DeadInside Yes you can. But as far as I know (and please correct me if I'm wrong) you can not easily POST with a filled body
  • 0
    @ruhe from my knowledge, the body of a post request is composed by all the content (or parameters) it is carrying (the "data" in an ajax call). I'm not sure I understand what you mean by filled body either
  • 4
    @ruhe with jQuery it's something like:

    var datuh = { "some" : "json" };
    $.ajax({
    type: "POST",
    url: "/wherever",
    contentType: 'application/json',
    data: JSON.stringify(datuh),
    success: function(resp) {
    //yay
    }
    });

    (Although of course, you http://youmightnotneedjquery.com)
  • 0
    @DeadInside that's exactly what I tried in my latest project. But then i noticed that the data is not passed to my backend as i expected. Instead, the json body was translated into x-www-form-urlencoded data and therefore the backend always received empty body POST requests. I later read an article about this problem which said that JQuery/Akax automatically translates such data into said x-www-form-urlencoded format.

    Of course I could be wrong but that's what I experienced
  • 4
    @ruhe uhh just use fetch if you can or otherwise axios. Never had problems with post requests with those
  • 5
    Not always true in ever project. Also maybe there is a reason why he needs a GET. Or maybe he wants to stay with the standard and you did use the wrong method type.
    To say I am done now eat it sucker is a very bad habbit for an Professional developer
  • 5
    The natural order must be respected! The server is on a lower architectural level than a consuming application so it calls the shots.

    The server determines the API, and the application consumes it. As it always has been. As it always shall be. Amen.
  • 2
    On the other hand, Duke Nukem said "come get some".
  • 0
  • 0
    So much rage... Just tell your front-end guy to add something in the header... 😅
Add Comment