What is the difference between doGet and doPost?

Answer Posted / janet

1. doGet() method is used to get information ,while
doPost() method is used for posting information.
2.doGet() requests can't send large amount of information
and is limited to 24-255 characters.How ever doPost()
requests passes all of it's data ,of unlimited length.
3. A doGet() request is appended to the request URL in a
query string and this allows the exchange is visible to the
client,where as a doPost() request passes directly over the
socket connection as part of its HTTP Request body and the
exchange are invisible to the client.

Is This Answer Correct ?    99 Yes 22 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the differences between servlet context vs servlet config?

677


What is api in servlet?

617


What is the inter-servlet communication?

791


What are the uses of servlet

709


Can we override destroy method in servlet?

607






How to rectify errors in java servlet while compilation?

589


How do you run a servlet?

628


Explain load on start-up and its importance?

695


The code in a finally clause will never fail to execute, right?

692


When a client request is sent to the servlet container, how does the container choose which servlet to invoke?

670


What is ServletConfig object?

687


Explain the concept of ssi ?

682


What is war file?

660


Which method of the httpservletrequest object is used?

662


What's the architecture of a servlet package?

636