what is http and how web works

the HTTP protocol & how the web works

The HTTP protocol

HTTP = __H__yper__t__ext __T__ransfer __P__rotocol

the HTTP is an application layer protocol that allows web-based applications to communicate and exchage data

the HTTP is the messager of the web

it is a TCP/IP based protocal

it is used to deliver contents,for example,images,videos,audios,documents,etc

the computers that communicate via HTTP must speak the http protocol

Three important things about the HTTP

1. HTTP is connectionless

after making the request,the client disconnet From the server,then when the response is ready the server re-establish the connection again and deliver the response

2. HTTP 's deliver variation

the HTTP can deliver any sort of data,as long as the two computers are able to read it

3. HTTP is stateless

the client and server know about each other just during the current request,if it closes,and the two computers want to connect again,they need to provide information to each other anew,and the connection is handled as the very first one

Why The HTTP

The HTTP was designed mainly to fetch html documents and sends it to the client

at the time 1991,it was created only for fetch html documents,not videos ,audios etc, it was designed for web.

It was designed in a exquisite way

It was being continually evolved and features were being added to it

It became the most convenient way to quickly and reliably move data on the web

How the Web works ? And How HTTP makes that possible

The URL format is:

schme://domain:port/path?query_string#fragment_id

schme: http,https,ftp,etc.
domain: www.google.com,etc.
port:80(default),3000,etc.
path:path_to_the_resource,this can be a series of folder names if you're getting a static web page that ends in the name of the file and its extenion

URLs also appear in HTML tags inside the resource,these can be for other resource like images,javascript,css, the attributes in these tags contain URLs that tell the browser go to location. for example:

 //when user click this, go to that page
 // go to this location and go get the file,it's a image, i wantto display it.

                    
                    

你可能感兴趣的:(随笔)