URI urn ISBN 0 395 36341 1 urn
Примеры URI urn: ISBN: 0 -395 -36341 -1 urn: uuid: 6 e 8 bc 430 -9 c 3 a-11 d 9 -9669 -0800200 c 9 a 66 urn: btih: JFRYN 46 FHYBNSWGH 66 HRJUU 57 HWEBNY magnet: ? xt=urn: btih: JFRYN 46 FHYBNSWGH 66 HRJUU 57 HWEBNY urn: ietf: rfc: 2648 http: //tools. ietf. org/html/rfc 2648 bitcoin: 6 Fhj 6 bsghf 3 FHTYNFGHhgfng 45 n 7 nd. Gf 3 A http: //aics. ru/index. shtml? a=showboard https: //google. com 5
Примеры URI ftp: //ftp. admin. tomsk. ru/pub/distr/ file: //C: Windowstemptxt. html#chapter 2 mailto: president@moscow. ru news: comp. lang. perl. misc sms: +1 -868 -123 -3423 telnet: //192. 168. 0. 1: 4352 data: text/html, <h 1>example</h 1> 6
URL (Universal Resource Locator) * Текущий URL (абсолютный URL) Относительный URL Результат http: //aics. ru/text/doc 1. html /files/logo. gif http: //aics. ru/text/doc 1. html doc 3. txt http: //aics. ru/text/doc 1. html . /doc 4. txt http: //aics. ru/text/doc 1. html . . /img/. /first. jpg http: //aics. ru/img/first. jpg http: //ya. ru/cat/ed/1. html . . /main/. . /2. html http: //ya. ru/2. html 7
10
Пример HTTP-запроса (метод GET) * GET http: //tpu. ru/img/tom. gif HTTP/1. 1 Accept: */* Referer: http: //tpu. ru/ User-Agent: Mozilla/4. 0 (compatible; MSIE 6. 0; Windows NT 5. 1) Host: tpu. ru Connection: close (пустая строка) GET /img/tom. gif HTTP/1. 1 Host: tpu. ru (пустая строка) 17
Пример HTTP-запроса (метод POST) * POST http: //aics. ru/temp/test. php HTTP/1. 1 Host: aics. ru Content-Type: application/x-www-form-urlencoded Content-Length: 46 18
Пример HTTP-ответа (статический документ) * HTTP/1. 1 200 OK Date: Wed, 14 Sep 2005 00: 31: 03 GMT Server: Apache/1. 3. 29 (Unix) PHP/4. 3. 5 Last-Modified: Thu, 11 Mar 2004 02: 24: 02 GMT ETag: "1509 a-14 e-f 865835 b" Content-Length: 8686 Content-Type: text/html; charset=WINDOWS-1251 <html>. . . 19
Пример HTTP-ответа (динамический документ) * HTTP/1. 1 200 OK Date: Sun, 02 Mar 2003 15: 56: 19 GMT Server: Apache/2. 0. 40 (Win 32) X-Powered-By: PHP/5. 0. 3 Content-length: 62 Connection: close Content-Type: text/html; charset=WINDOWS-1251 <html>. . . 20
- Slides: 20