Page 1 of 1

About Question enthuware.jwpv6.2.1093 :

Posted: Sat Aug 13, 2016 12:05 pm
by johnlong
Would it be possible to override doPut to receive and process file as asked in the question?

Re: About Question enthuware.jwpv6.2.1093 :

Posted: Sat Aug 13, 2016 12:49 pm
by admin
Yes, it is probably possible but it is certainly not something that "you would use", which is what the question asks. For the purpose of the exam, doPost is the right answer.

HTH,
Paul.

Re: About Question enthuware.jwpv6.2.1093 :

Posted: Mon Aug 15, 2016 11:11 am
by johnlong
What is the advantage of using doPost instead of doPut in this case?

Re: About Question enthuware.jwpv6.2.1093 :

Posted: Mon Aug 15, 2016 11:36 am
by admin
It is not about advantage. It is about how the protocol is designed. HTTP protocol specifies that PUT is used to associate a resource with a URL while POST is used to process data sent by the browser. One can, of course, write a client/server pair that does just the opposite and it would work but that is not the point here.

HTH,
Paul,

Re: About Question enthuware.jwpv6.2.1093 :

Posted: Wed Aug 17, 2016 1:54 pm
by johnlong
Thank you for your explanation!