The HTTP POST Command

So far, the only HTTP command you have seen in this chapter is the GET command. As you know, the POST command is also frequently used to send form information to the Web server. Technically, the POST command can be used for more things than just form data, but form data is by far the most common kind of data sent via POST.

When a browser sends a POST command, the first line of the request looks just like the GET request, except that instead of GET, the command is POST. The difference comes about just after the request header. In a GET request, there is no data after the request header. After the server sees the blank line indicating the end of the header, it processes the request. In a POST request, the browser sends the ...

Get Special Edition Using Java™ 2 Enterprise Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.