⊗inhpAdvFMP 23 of 29 menu

Submitting forms using the POST method in the HTTP protocol

Let's now send the form using the POST method. Let's specify the appropriate value for the method attribute:

<form action="/page/" method="POST"> <input name="test1"> <input name="test2"> <input type="submit"> </form>

After clicking the send button, the following HTTP request will be executed:

POST /page/ HTTP/1.1

As you can see, when sending with this method, the request URI will not contain the form data. This data will be contained in the request body as a Query String:

test1=value1&test2=2

Make a form that sends data using the POST method and submit it to some site.

After submitting the form, examine the URL content and make sure that there are no GET parameters when submitting the form in this way.

Try refreshing the page after submitting the form. What happens?

In the browser debugger, find the "Payload" tab. See what it contains.

English
AfrikaansAzərbaycanБългарскиবাংলাБеларускаяČeštinaDanskDeutschΕλληνικάEspañolEestiSuomiFrançaisहिन्दीMagyarՀայերենIndonesiaItaliano日本語ქართულიҚазақ한국어КыргызчаLietuviųLatviešuМакедонскиMelayuမြန်မာNederlandsNorskPolskiPortuguêsRomânăРусскийසිංහලSlovenčinaSlovenščinaShqipСрпскиSrpskiSvenskaKiswahiliТоҷикӣไทยTürkmenTürkçeЎзбекOʻzbekTiếng Việt
We use cookies for website operation, analytics, and personalization. Data processing is carried out in accordance with the Privacy Policy.
accept all customize decline