Introduction to HTTP protocols and software for AJAX learning installation

Source: Internet
Author: User
Tags php server

The 1:HTTP protocol is a stateless protocol that does not maintain a persistent connection, the browser sends a request to the server, and the server promises not to shut down the connection. Next time you need to relax again.

2:http request, Method (Get,post), address (URL), request header (authentication information, client environment), request body (Submitted content, form information, query information)

3:http Response three parts, (numeric status code, indicates a successful or failed request) 404, etc., response header (server type, date, cache = =), Response body (content, query content)

HTTP request message

HTTP response Messages

Status code:

4:xmlhttprequest object used for page flush asynchronous operations

Open (Method,url,async)//Send request Async parameter indicates synchronous request or asynchronous request, true indicates asynchronous request, false indicates synchronous request, default is True

Send (string);//Post send data to the server, GET request content for Null,post request to fill in the content of the submission.

5:xmlhttprequest response

Object returned by the Send () method

Property: ReadyState: A state indicating whether the request was successful

Server snooping and requests

Construction and testing of the environment

1: Download XAMPP Integration Server database and PHP Server Software//self-Baidu download

2:dreamwear establish a site and establish a local server selection Php/mysql

PHP files need to be placed under the htpdos/folder in the XAMPP installation directory//

Client-side Test files: Test the network using a plugin from the postman Google Explorer

51557804//Blog Tutorial

GET request Test

POST request test

application/x-www-form-urlencoded for content Plain text encoding

Introduction to HTTP protocols and software for AJAX learning installation

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.