Sending Data to a Server

So far, all the HTTP calls covered in this chapter have been used to obtain data from an Internet server. Obviously, if you intend to use HTTP to access, for example, enterprise databases, you will need to send data back to the server. This can be done by doing the following:

  • Appending data onto the URL. This technique is used when small amounts of data are to be sent. Special characters, such as spaces, need to be encoded to ensure that the URL only contains legal characters.

  • Using the "POST" HTTP verb. You can send large amounts of data, including whole files.

The first technique is the easier to use, but the second is more flexible.

Sending Data with the URL

Data is appended onto a URL following a "?" character. The ...

Get Windows® CE 3.0 Application Programming 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.