Building and Managing Web Sites - PowerPoint PPT Presentation

About This Presentation
Title:

Building and Managing Web Sites

Description:

GET and POST are primary types. Server Fundamentals. 4. Web Server Fundamentals ... User-Agent: Mozilla/4.01. The server sends a response back to the client: ... – PowerPoint PPT presentation

Number of Views:50
Avg rating:3.0/5.0
Slides: 10
Provided by: chris730
Category:

less

Transcript and Presenter's Notes

Title: Building and Managing Web Sites


1
Building and Managing Web Sites
  • HTTP Fundamentals

2
HTTP Introduction
  • HTTP -- Hypertext Transfer Protocol
  • HTTP is the protocol that WWW requests are based
    upon.
  • Standard maintained by W3C at http//www.w3.org/Pr
    otocols/
  • HTTP specification defines how client requests
    content from a server and how a server returns a
    response to the client.

3
HTTP Introduction
  • Two different versions, 1.0 and 1.1
  • Version 1.1 more efficient with larger pages.
  • HTTP supports many request types
  • PUT and DELETE not commonly used
  • GET and POST are primary types.

4
Web Server Fundamentals
  • A webserver is software that does the following
  • Server receives requests from browser/client for
    resources
  • A resource is any chunk of information that can
    be identified by a URL like HMTL or image files,
    scripts, streaming media, etc.
  • Server retrieves and/or processes the resource
  • Server sends the resource back to the client
  • Server logs the transaction
  • Responses/requests occur using the HTTP protocol,
    typically on port 80

5
Sample HTTP Exchange
  • To retrieve the resource at http//www.host.com/pa
    th/file.html
  • Browser sends request to host www.host.com, port
    80
  • GET /path/file.html HTTP/1.0
  • From 105.123.456.789
  • User-Agent Mozilla/4.01
  • The server sends a response back to the client
  • HTTP/1.0 200 OK
  • Date Fri, 31 Dec 1999 235959 GMT
  • Content-Type text/html
  • Content-Length 1354
  • lthtmlgtltbodygtlth1gtHappy New Millenium!lt/h1gt
  • (more file contents)
  • lt/bodygt
  • lt/htmlgt

6
Response Status Line
  • Includes three parts separated by spaces
  • the HTTP version
  • a response status code that gives the result of
    the request
  • An English reason phrase describing the status
    code.
  • Typical status lines are
  • HTTP/1.0 200 OK or
  • HTTP/1.0 404 Not Found

7
Common Response Status Codes
  • 200 OK - Request succeeded, resulting resource is
    returned in the message body
  • 404 Not Found --The requested resource doesn't
    exist.
  • 301 Moved Permanently
  • 302 Moved Temporarily
  • 303 See Other (HTTP 1.1 only) Resource has moved
    to another URL (given by the Location response
    header), and should be automatically retrieved by
    the client.
  • 500 Server Error -- Unexpected server error.
    Common caused by a server-side script that has
    bad syntax, fails, or otherwise can't run
    correctly.

8
Response Content-Type
  • Response header includes Content-Type to tell
    client/browser how to handle the resource
    (display a browser or launch an
    application/plug-in)
  • Based on MIME types for email attachments
  • Broad types text, image, audio, video,
    application
  • Many different subtypes, always new ones.
  • E.g., Content-Type text/html
  • Most webservers software have a list of common
    types must define new subtypes on webserver

9
FrontPage and HTTP
  • FrontPage uses the HTTP commands PUT and DELETE
  • FrontPage can be sensitive to Proxy Servers that
    intercept HTTP requests.
  • Can also attach via FTP.
Write a Comment
User Comments (0)
About PowerShow.com