Ad

Sunday, June 17, 2018

XMLHttpRequest Basics API GET

response : variableName.status  // returns 200, variableName.statusText // returns "OK"

request: 
     open(method,url,async)
     send(string)
     
     var xmlhttp = new XMLHttpRequest();
     xmlhttp.open('GET', 'process.php', true);
     xmlhttp.send();

Response


-------
GET POST PUT DELETE
(Create Retrieve Update Delete CRUD)

  •      Get - retrieves info from the specified source
  • POST- sends new information to the specified source
  • Put - updates existing info of the specified source
  • Delete - removes existing info from the specified source
Status
  • 1xx server working on the request
  • 2xx okay
  • 3xx have to do something else first
  • 4xx error
  • 5xx server problem     

No comments:

Post a Comment

Applying for jobs at the Lending Club

We tried to figure out Lending Club 's tech stack for 2019. Our analysis shows Lending Club asks for skills in Python, Tableau, SQL and ...