
Before we can get right into working with Ajax, we need to understand some concepts. When we’re talking about sending and retrieving data from the server, we’re talking about HTTP requests. HTTP requests is an important part of the web, it allows us to exchange data with external or internal hosts.
There are two distinct types of HTTP requests that you need to know: GET and POST. While they may seem similar, they both have their specific uses, and being able to decide which is use is important.
GET requests essentially just request a file from a server. However, it is also possible to pass parameters and values along with the request. If you’ve ever noticed question marks and ampersands in a URL, then you’ve noticed a GET request. GET requests use the URL to pass those parameters and values to the server. This makes GET requests an insecure method of sending the server data. However, since not all data needs to be secure, GET requests are still useful. Take a search query, for example. A search query is not something that needs to be transmitted in a secure way (compared to a password, which should always use a secure method), so a GET request will do perfectly.
POST requests essentially send data to the server. Unlike GET requests, POST requests are secure because they don’t use the URL to transmit the data. POST requests also transmit a URL, just like GET requests. As well, just like GET requests again, it is possible to receive data back from the server with a POST request. Because POST requests send their parameters and values in a secure way, it is more suitable for transmitting passwords and personal details (from a form or otherwise) than GET requests are.
Another difference between GET and POST requests is that GET requests are, by default, cached by browsers, while POST requests are not cached by browsers. This is because POST requests can contain sensitive data, as well submitting the POST data more than once could have negative side effects with poorly programmed websites.
Now that you’re aware of the differences between GET and POST HTTP requests, we’ll be able to begin with the basics of Ajax next week.





data recovery software
June 30, 2009 10:09 pm
I don’t know much about GET and POST but I was in the graduation then I have read this topic im my computer chapter and GET and POST are the query of the Computer Language