Você está na página 1de 19

CS 081 HTML and Web Programming Lecture 1

THE INTERNET AND WORLD


WIDE WEB
internet vs. Internet
An internet (lower case i) refers to a network
of networks.
The Internet (upper case I) refers to the
global internet that connects everyone to.
Uniform Resource Locator
http://www.somedomain.com/path
Protocol or Scheme
host
path
Uniform Resource Locator
www.somedomain.com
subdomain
subdomain
Top-level-domain
ICANN
Internet Corporation for Assigned
Names and Numbers
Management of most top-level domains
Management of IP Addresses
Internet Assigned Numbers Authority
(IANA)
DNS
Domain Name System
A service that converts IP Addresses into human
friendly computer hostnames.
Name Servers contain tables of IP Address and
Domain Name pairs. These servers can be queried
with requests to resolve domain names into IP
addresses. These servers are periodically synced.
Name Servers are organized by ICANN (Internet
Corporation for Assigned Names and Numbers)
which manages the registrars whom conduct
business with end users.
The World Wide Web
While the Internet refers to the global
network of interconnected computers, the
world wide web refers to the publically
available files through the HTTP protocol.
The World Wide Web
Tim Berners-Lee us credited as the inventor of the
World Wide Web while working at CERN (European
Organization for Nuclear Research)
His original idea involved the idea of hypertext
(text with an embedded link to another resource)
The project was meant to be used to make sharing
articles among colleagues easier. The
convenience of hypertext and the fact that the
technology was supply for free, led to its quick
adoption.
Client Server Model
In the client-server model there are 2 types of
systems, client systems from server systems.
A client system is designed to send requests to the
server and process any results the server sends to
the client.
A server system (particularly web server) is designed
to take requests from various clients.

Client: Send Request, Receive Reply


Server: Receive Request, Send Reply
HTTP Request

HTTP Response + Optional File


HTTP
Hypertext Transfer Protocol is a communications protocol that allows
the transfer of documents in a client/server type relationship.
It is a simple protocol with seven commands only two of which are
often used.
GET
POST
PUT
DELETE
HEAD
OPTIONS
TRACE
CONNECT
PATCH
HTTP Requests
HTTP Requests are structured text, they
contain:
The location of the requested file.
The request type
ie. GET, POST, HEAD
Extra information for the server
HTTP Request Example
GET /folderName/file.html HTTP/1.1
Host: www.somewebsite.com
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.2.13)
Gecko/20101203 Firefox/3.6.13
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
Accept-Language: en-us,en;q=0.5
Accept-Encoding: gzip,deflate
Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7
Keep-Alive: 115
Connection: keep-alive
Referer: http://www.google.com/url?sa=t&soce=web&c30CCc...
X-Behavioral-Ad-Opt-Out: 1
HTTP Responses
HTTP Responses are composed of 2 parts, the
header and an optional file:
The header is structured text
The Servers response code
200 OK
403 Forbidden
404 Not Found
Extra information from the server
It is then followed by the optional file, that can be
any format
HTTP Response Example
HTTP/1.1 200 OK
Date: Fri, 31 Dec 1999 23:59:59 GMT
Content-Type: text/plain
Content-Length: 42
some-footer: some-value
another-footer: another-value
[Blank Line]
[Start of Webpage HTML]
Browser
Browsers automate the process of creating
and sending HTTP Requests and receiving
HTTP Responses.
They also attempt to display the result if the
browser understands the format.
All the browser needs is the location of the
file.
User types in
google.com
Browser appends extra information
and sends HTTP Request to server

GET / HTTP/1.1
Host: www.google.com

HTTP/1.1 200 OK

[HTML code for the webpage located


at http://www.google.com/index.html]
Server sees request for a directory, returns
Web Server directory index page
W3C and Web Standardization
The World Wide Web Consortium was founded in
1994 to address the problem of incompatible
versions of HTML that arose from having no
formal standard.
As vendor's started to add and duplicate
features, inconsistencies between browsers
started appearing.
The W3C developed standards that vendors
agreed to follow in order to keep some
consistency between web pages.
The Internet Today/ Tomorrow
Search Engines
Cloud Computing
Decentralized Computing
HTML5
Mobile Devices

Você também pode gostar