What is the difference between Difference between doGet() and doPost()?

Questions by ganeshreddy_4u@yahoo.co.in

Showing Answers 1 - 14 of 14 Answers

Amit

  • Mar 23rd, 2006
 

Same as Get and Post

  Was this answer useful?  Yes

Nagarajan

  • Mar 24th, 2006
 

      doGet()  > This Method used to get data from the database.

      doPost() > This Method used to post data via web forms to database.

        we will post data via doPost() it will clearly shown the posted data in the URL line.It is not secure.

        But, using doGet() the posted data will hide.so that we use doGet() for

posting data also.

Thanks

Nagarajan B.Tech

  Was this answer useful?  Yes

reshmarout

  • Mar 27th, 2006
 

The main difference doGET() and doPOST() is that:

doGET() is having limited length,i.e 1024 charaters,where as doPOST() can accept unlimited characters.

  Was this answer useful?  Yes

sudheer

  • Mar 31st, 2006
 

doget() method shows the details where as dopost method doesnt shows in information

and doget method is limited by characters(1024)...

..sudheer.k

  Was this answer useful?  Yes

manish

  • Apr 2nd, 2006
 

is it possible to see data in case of doPost().

I think in case of doGet(),data is shown in URL.

but in case of doPost() it is secure, it makes a new socket connection to send data.

will u clearify  it.

  Was this answer useful?  Yes

As we know that the doGet() function has limited character string to send to the server and this character string query is added with the Url. while doPost() send the query string with the request body so this is secure data and doPost() carry out the data in the bulk.

  Was this answer useful?  Yes

Madhavikari

  • Apr 17th, 2006
 

DoGet

DoPost

In doGet Method the parameters are appended to the URL and sent along with header information

In doPost, parameters are sent in separate line in the body

Maximum size of data that can be sent using doget is 240 bytes

There is no maximum size for data

Parameters are not encrypted

Parameters are encrypted

DoGet method generally is used to query or to get some information from the server

Dopost is generally used to update or post some information to the server

DoGet is faster if we set the response content length since the same connection is used. Thus increasing the performance

DoPost is slower compared to doGet since doPost does not write the content length

DoGet should be idempotent. i.e. doget should be able to be repeated safely many times

This method does not need to be idempotent. Operations requested through POST can have side effects for which the user can be held accountable, for example, updating stored data or buying items online.

DoGet should be safe without any side effects for which user is held responsible

This method does not need to be either safe

  Was this answer useful?  Yes

prabhaker

  • May 19th, 2006
 

sorry for doGet it will apper as a string URL in the browser window.

where as in do Post it will be hidden in the request header.

By using doGet we can't send more than 2kb data,where by using doPost we can do.

  Was this answer useful?  Yes

vrushali

  • Jul 25th, 2006
 

Yes, the in doget() method the request appear as a part of URL. The maximum siZe of data for doget() method is 2k.In case of dopst() method ,data doesn't appear as a part of URL.Also there is no limit on max. size of data.

  Was this answer useful?  Yes

Vrushank

  • Aug 2nd, 2006
 

doGet() method is not secure. It shows the request attributes as in url re-writiing. Whereas doPost() send this data as a part of header so it is much secured.

  Was this answer useful?  Yes

Rajasekar

  • Nov 6th, 2006
 

doGet() -> limited data can send ( max 2kb)

               parameters will be seen in the address bar

               its faster that doPost()

doPost() -> no limitations for sending data

                 parameters will not seen in the address bar

                 but it is slower than doGet()

  Was this answer useful?  Yes

The major difference between the doGet() and doPost() methods is that in doGet() method wats the paramaters is passing can be seen in url but in doPost() method we cant see the parameters in url thats the difference upto my knowledge

  Was this answer useful?  Yes

praveen7g

  • Jun 5th, 2008
 

when you use doget() method the formfield data is passed to the server as part of query string so there is no confidential to the data ,every body can see that data

and one more is we can send very limited data to the server by using doget() method.

if you want to send the large amount of data and if your data want to be secure we have to go for doPost().

  Was this answer useful?  Yes

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

 

Related Answered Questions

 

Related Open Questions