1. Http protocol
In addition to TCP / IP protocol, http can be said to be the most important and the most used network protocol.This section briefly describe the working principle of http protocol.
Suppose now that there is a html file: http.html, stored in Web server, the URL for the www.myweb.com / http.html, the file says:
HTML code:
hello, http
Now, a user via IE to access the address, IE first of this address is converted to a domain name through DNS IP address, and then open a Web server port (default is 80, not 80 to be added after the domain name ": portNo. ", for example www.myweb.com:81) connected, and then send a http request like this (using flashget to download files such as downloaded software, in the details where the information can also be observed):
GET / http.html HTTP/1.1
Host: www.myweb.com
Accept: backup/100408 backup/task_index_20100409.tar.gz bin / analyse bin / categories.txt bin / constant.sh bin / crawl.sh bin / download bin / functions bin / manual bin / task data / articles data / pages data /seeds data / tasks log / analyse log / archive.log log/archive.log.2010-04-07.log log/archive.log.2010-04-09.log log / download log/download_010406.log log / runalltask.log log/task_100.log log/task_101.log log/task_102.log log/task_103.log log/task_104.log log/task_105.log log/task_106.log log/task_107.log log/task_108.log log/task_109.log log/task_110.log log/task_111.log log/task_112.log log/task_113.log log/task_114.log log/task_115.log log/task_116.log log/task_117.log log/task_118.log log/task_119.log log/task_120.log log/task_121.log log/task_122.log log/task_131.log log/task_132.log log/task_139.log log/task_140.log log/task_46_download_1_check.log log/task_46_download_2_check.log log/task_46_download_3_check.log log/task_46_download_4_check.log log/task_46_download_5_check.log log/task_46_download_6_check.log log/task_79.log log/task_80.log log/task_81.log log/task_82.log log/task_83.log log/task_84.log log/task_85.log log/task_86.log log/task_87.log log/task_88.log log/task_89.log log/task_90.log log/task_91.log log/task_92.log log/task_94.log log/task_95.log log/task_98.log log/task_99.log log / www.articlesbase.com log/www.soft6.com maint / DbAccess maint / crawl maint / libs maint/xml2dict-2008.6-tar.gz svn / src tmp/1.dat tmp/1002_format_2010051320101002.dat tmp/10095_wget_all.dat tmp/10103 tmp/10103_urls.dat tmp/10108_format_2010051320104454.dat tmp/10142_wget_all.dat tmp/10165_wget_113_128.txt tmp/10165_wget_129_144.txt tmp/10165_wget_145_160.txt tmp/10165_wget_17_32.txt tmp/10165_wget_1_16.txt tmp/ 10165_wget_33_48.txt tmp/10165_wget_49_64.txt tmp/10165_wget_65_80.txt tmp/10165_wget_81_96.txt tmp/10165_wget_97_112.txt tmp/10165_wget_all.dat tmp/10189_format_2010051320103835.dat tmp/10371_format_2010051320104540.dat tmp/10392_format_2010051320103704.dat tmp/1042_format_2010051320105937.dat tmp/ 1042_in.pipe tmp/1042_index_201005131459.dat tmp/1042_out.pipe tmp/10461 tmp/10461_urls.dat tmp/10523_wget_all.dat tmp/10575_format_2010051420103001.dat tmp/10627_format_2010051420103001.dat tmp/10674_format_2010051320104616.dat tmp/10874_format_2010051420102030.dat tmp/10971_wget_all. dat tmp/11054_wget_all.dat tmp/11092 tmp/11131_format_2010051320102544.dat tmp/11147 tmp/11147_urls.dat tmp/11217_wget_all.dat tmp/11241_format_2010051320103932.dat tmp/11241_in.pipe tmp/11241_index_201005131539.dat tmp/11241_out.pipe tmp /11430_format_2010051420104330.dat tmp/11430_in.pipe tmp/11430_index_201005141043.dat tmp/11430_out.pipe tmp/11630_format_2010051320104557.dat tmp/11630_in.pipe tmp/11630_index_201005131645.dat tmp/11630_out.pipe tmp/11770_wget_all.dat tmp/11774_format_2010051320102245.dat tmp /11918 tmp/11954_wget_all.dat tmp/11984_format_2010051320105322.dat tmp/11984_in.pipe tmp/11984_index_201005131953.dat tmp/11984_out.pipe tmp/12010_format_2010051320104717.dat tmp/12097_format_2010051420100911.dat tmp/12097_in.pipe tmp/12097_index_201005141109.dat tmp/12097_out.pipe tmp/12141 tmp/12141_urls.dat tmp/12204_wget_all.dat tmp/12264_wget_all.dat tmp/12427 tmp/12427_urls.dat tmp/12518_wget_all.dat tmp/12599_urls.dat tmp/12694_format_2010051320104916.dat tmp/12694_in.pipe tmp/12694_out. pipe tmp/12706_format_2010051320105833.dat tmp/12744_wget_all.dat tmp/12747_wget_all.dat tmp/12928 tmp/12928_urls.dat tmp/12946 tmp/12946_urls.dat tmp/12952_format_2010051320103430.dat tmp/12956_wget_all.dat tmp/12971_format_2010051320104951.dat tmp /12989_format_2010051320104021.dat tmp/12990_wget_all.dat tmp/13026_wget_all.dat tmp/13099 tmp/13099_urls.dat tmp/13167_format_2010051320102612.dat tmp/13224_format_2010051320104954.dat tmp/13224_in.pipe tmp/13224_out.pipe tmp/13234_format_2010051320102332.dat tmp/13352_wget_all.dat tmp/13356 tmp/13434 tmp/13434_urls.dat tmp/13439_format_2010051320102506.dat tmp/13475_format_2010051320104708.dat tmp/13475_in.pipe tmp/13475_index_201005131647.dat tmp/13475_out.pipe tmp/13496_wget_all.dat tmp/13554_format_2010051420104550.dat tmp/13554_in. pipe tmp/13554_index_201005141045.dat tmp/13554_out.pipe tmp/13665 tmp/13665_urls.dat tmp/13727_wget_all.dat tmp/13738_format_2010051320105005.dat tmp/13738_in.pipe tmp/13738_out.pipe tmp/1373_wget_all.dat tmp/13786_wget_13_16.txttmp/13786_wget_17_20.txt tmp/13786_wget_21_24.txt tmp/13786_wget_25_28.txt tmp/13786_wget_29_32.txt tmp/13786_wget_33_36.txt tmp/13786_wget_37_40.txt tmp/13786_wget_41_44.txt tmp/13786_wget_45_48.txt tmp/13786_wget_49_52.txt tmp/13786_wget_5_8.txttmp/13786_wget_9_12.txt tmp/1380_wget_all.dat tmp/13840 tmp/13913 tmp/13913_urls.dat tmp/13975_wget_1_10.txt tmp/13975_wget_all.dat tmp/14040_format_2010051320105840.dat tmp/14196_wget_all.dat tmp/14198 tmp/14258_format_2010051320105136.dat tmp/ 14308_format_2010051320105113.dat tmp/14308_in.pipe tmp/14308_index_201005131851.dat tmp/14308_out.pipe tmp/14316 tmp/14316_urls.dat tmp/14343_wget_all.dat tmp/14378_wget_1_10.txt tmp/14378_wget_all.dat tmp/14552 tmp/14552_urls.dattmp/1458 tmp/1458_urls.dat tmp/14602 tmp/14616_wget_113_128.txt tmp/14616_wget_129_144.txt tmp/14616_wget_145_160.txt tmp/14616_wget_17_32.txt tmp/14616_wget_1_16.txt tmp/14616_wget_33_48.txt tmp/14616_wget_49_64.txt tmp/14616_wget_65_80.txt tmp/14616_wget_81_96.txt tmp/14616_wget_97_112.txt tmp/14616_wget_all.dat tmp/14621_format_2010051320103920.dat tmp/1481_wget_all.dat tmp/14943_wget_all.dat tmp/14967_format_2010051420105952.dat tmp/14967_in.pipe tmp/14967_index_201005141059.dat tmp/14967_out.pipe tmp/1496_wget_all.dat tmp/15226_format_2010051320104722.dat tmp/15226_in.pipe tmp/15226_index_201005131647.dat tmp/15226_out.pipe tmp/1522_wget_all.dat tmp/1523_format_2010051320105149.dat tmp/15346 tmp/15346_urls.dat tmp/15408_wget_all.dat tmp/ 15506_wget_all.dat tmp/15539 tmp/15539_urls.dat tmp/15601_wget_all.dat tmp/16196 tmp/16196_urls.dat tmp/16254_format_2010051220103711.dat tmp/16262_wget_all.dat tmp/1628_format_2010051320102313.dat tmp/16348_format_2010051320102314.dat tmp/16348_in.pipetmp/16348_out.pipe tmp/1643 tmp/16996_format_2010051320105735.dat tmp/17091_format_2010051320104804.dat tmp/17091_in.pipe tmp/17091_index_201005131648.dat tmp/17091_out.pipe tmp/17105_format_2010051420100346.dat tmp/17113_format_2010051420100346.dat tmp/17116_wget_all.dat tmp /17125_wget_all.dat tmp/17139_format_2010051320101958.dat tmp/17139_in.pipe tmp/17139_index_201005131619.dat tmp/17139_out.pipe tmp/17173_format_2010051320101206.dat tmp/17345 tmp/17345_urls.dat tmp/17407_wget_all.dat tmp/1741_wget_all.dat tmp/17473_wget_all.dat tmp/1757_format_2010051320102156.dat tmp/17650 tmp/1774_format_2010051320101604.dat tmp/17763_wget_all.dat tmp/17784_format_2010051420102902.dat tmp/17784_in.pipe tmp/17784_index_201005141229.dat tmp/17784_out.pipe tmp/17926_format_2010051320101621.dat tmp/17926_in.pipe tmp/ 17926_out.pipe tmp/18199 tmp/18199_urls.dat tmp/18285_wget_all.dat tmp/18329 tmp/18341 tmp/18438_format_2010051320105636.dat tmp/18438_in.pipe tmp/18438_index_201005131856.dat tmp/18438_out.pipe tmp/18462 tmp/18724_format_2010051420100234.dat tmp/18724_in.pipe tmp/18724_index_201005141102.dat tmp/18724_out.pipe tmp/18729_format_2010051420100411.dat tmp/18729_in.pipe tmp/18729_index_201005141304.dat tmp/18729_out.pipe tmp/18750_wget_all.dat tmp/18841_format_2010051320100438.dat tmp/18852_format_2010051320101751.dat tmp/18852_in.pipe tmp/18852_out.pipe tmp/1898 tmp/1898_urls.dat tmp/19039_format_2010051320104921.dat tmp/19136 tmp/19136_urls.dat tmp/19198_wget_113_128.txt tmp/19198_wget_129_144.txt tmp/19198_wget_145_160.txt tmp/19198_wget_17_32. txt tmp/19198_wget_1_16.txt tmp/19198_wget_33_48.txt tmp/19198_wget_49_64.txt tmp/19198_wget_65_80.txt tmp/19198_wget_81_96.txt tmp/19198_wget_97_112.txt tmp/19198_wget_all.dat tmp/19236 tmp/19318_format_2010051420100051.dat tmp/19372_format_2010051420104818.dattmp/19372_in.pipe tmp/19372_index_201005141248.dat tmp/19372_out.pipe tmp/19376 tmp/19376_urls.dat tmp/19564_wget_all.dat tmp/1960_wget_all.dat tmp/1963_format_2010051420104602.dat tmp/1963_in.pipe tmp/1963_index_201005141346.dat tmp /1963_out.pipe tmp/19652 tmp/19850_format_2010051320100113.dat tmp/19850_in.pipe tmp/19850_index_201005132001.dat tmp/19850_out.pipe tmp/19923_format_2010051420100139.dat tmp/19923_in.pipe tmp/19923_index_201005141101.dat tmp/19923_out.pipe tmp/19937_wget_all.dat tmp/19961 tmp/19961_urls.dat tmp/20027_wget_all.dat tmp/20058 tmp/2011_format_2010051320105302.dat tmp/20159_format_2010051320100011.dat tmp/20159_in.pipe tmp/20159_out.pipe tmp/20402_format_2010051420105758.dat tmp/20402_in.pipe tmp/20402_index_201005141257. dat tmp/20402_out.pipe tmp/2044 tmp/20455_format_2010051420103811.dat tmp/20504 tmp/20805_format_2010051420101701.dat tmp/20805_in.pipe tmp/20805_index_201005141217.dat tmp/20805_out.pipe tmp/20874 tmp/21061_format_2010051420100401.dat tmp/21061_in.pipe tmp/21061_index_201005142004.dat tmp/21061_out.pipe tmp/21205_format_2010051320100344.dat tmp/21380 tmp/21380_urls.dat tmp/21416 tmp/21416_urls.dat tmp/21476 tmp/21478_wget_all.dat tmp/21499_format_2010051320103835.dat tmp/21499_in.pipetmp/21499_out.pipe tmp/2152 tmp/21520 tmp/21545_wget_all.dat tmp/21640_format_2010051420103709.dat tmp/21640_in.pipe tmp/21640_index_201005141237.dat tmp/21640_out.pipe tmp/21649_wget_all.dat tmp/21670_format_2010051320101957.dat tmp/21718 tmp/ 21718_urls.dat tmp/21780_wget_all.dat tmp/21801_format_2010051320103922.dat tmp/21801_in.pipe tmp/21801_out.pipe tmp/21836_wget_all.dat tmp/21879_format_2010051420100546.dat tmp/21879_in.pipe tmp/21879_index_201005141305.dat tmp/21879_out.pipe tmp/ 21983 tmp/21983_urls.dat tmp/22045_wget_all.dat tmp/22081_format_2010051320101701.dat tmp/22419_wget_all.dat tmp/2252_format_2010051320100217.dat tmp/2252_in.pipe tmp/2252_index_201005131502.dat tmp/2252_out.pipe tmp/22599_format_2010051420101318.dat tmp/22789_format_2010051220102419. dat tmp/2286_format_2010051420104125.dat tmp/2286_in.pipe tmp/2286_index_201005141241.dat tmp/2286_out.pipe tmp/23004_format_2010051320104014.dat tmp/23004_in.pipe tmp/23004_out.pipe tmp/23193 tmp/23193_urls.dat tmp/23255_wget_all.dattmp/2346_wget_all.dat tmp/24018_format_2010051320104027.dat tmp/24018_in.pipe tmp/24018_out.pipe tmp/2411_format_2010051420105625.dat tmp/2411_in.pipe tmp/2411_index_201005141256.dat tmp/2411_out.pipe tmp/24184 tmp/24184_urls.dat tmp /24250_wget_all.dat tmp/24319 tmp/24319_urls.dat tmp/24380_format_2010051320100208.dat tmp/24380_in.pipe tmp/24380_out.pipe tmp/24381_wget_all.dat tmp/2438_format_2010051320101018.dat tmp/24472_format_2010051420105511.dat tmp/2459_format_2010051220104021.dat tmp/2459_in.pipe tmp/2459_out.pipe tmp/24901_wget_all.dat tmp/24970_format_2010051320102634.dat tmp/25024_format_2010051320104904.dat tmp/25095_format_2010051320104155.dat tmp/25095_in.pipe tmp/25095_out.pipe tmp/25258 tmp/25287 tmp/25287_urls.dat tmp/25349_wget_all. dat tmp/25402_format_2010051220101213.dat tmp/25402_in.pipe tmp/25402_out.pipe tmp/25481_format_2010051420105918.dat tmp/25481_in.pipe tmp/25481_index_201005141059.dat tmp/25481_out.pipe tmp/25569_wget_all.dat tmp/25665_format_2010051320102650.dat tmp/25706_format_2010051220101342. dat tmp/25706_in.pipe tmp/25706_out.pipe tmp/25767_format_2010051420101723.dat tmp/25875 tmp/25875_urls.dat tmp/25901_format_2010051220101416.dat tmp/25901_in.pipe tmp/25901_out.pipe tmp/25906 tmp/25906_urls.dat tmp /25941_wget_all.dat tmp/25945 tmp/2598 tmp/2598_urls.dat tmp/26064_format_2010051320104219.dat tmp/26064_in.pipe tmp/26064_out.pipe tmp/26066_format_2010051320102150.dat tmp/26069_wget_all.dat tmp/26071_format_2010051320105110.dat tmp/26071_in.pipe tmp/ 26071_out.pipe tmp/26092_format_2010051420103857.dat tmp/26092_in.pipe tmp/26092_index_201005141238.dat tmp/26092_out.pipe tmp/26102_format_2010051220101533.dat tmp/26102_in.pipe tmp/26102_out.pipe tmp/26217_wget_all.dat tmp/26242 tmp/26301_format_2010051320105633. dat tmp/26301_in.pipe tmp/26301_index_201005131956.dat tmp/26301_out.pipe tmp/26348 tmp/26348_urls.dat tmp/26360_format_2010051320104800.dat tmp/26360_in.pipe tmp/26360_index_201005131848.dat tmp/26360_out.pipe tmp/26381_wget_all.dattmp/26411_wget_all.dat tmp/26536_format_2010051220101835.dat tmp/26536_in.pipe tmp/26536_out.pipe tmp/2663_wget_all.dat tmp/26671_format_2010051320100448.dat tmp/26800_format_2010051220101924.dat tmp/26800_in.pipe tmp/26800_out.pipe tmp/26930_format_2010051220102001.dattmp/26930_in.pipe tmp/26930_out.pipe tmp/27126_format_2010051320104305.dat tmp/27126_in.pipe tmp/27126_out.pipe tmp/2712_format_2010051320103828.dat tmp/2712_in.pipe tmp/2712_index_201005131538.dat tmp/2712_out.pipe tmp/27159_format_2010051220102227.dattmp/27159_in.pipe tmp/27159_out.pipe tmp/27935 tmp/27956_wget_all.dat tmp/28070_format_2010051420104010.dat tmp/28070_in.pipe tmp/28070_index_201005141240.dat tmp/28070_out.pipe tmp/28200 tmp/28200_urls.dat tmp/28215_format_2010051320105433.dat tmp/28274_wget_all.dat tmp/28286_format_2010051420101444.dat tmp/2839 tmp/28404_format_2010051320105149.dat tmp/28404_in.pipe tmp/28404_out.pipe tmp/28465_wget_all.dat tmp/28554 tmp/28554_urls.dat tmp/28707_wget_all.dat tmp/28952_format_2010051320100238. dat tmp/28957_wget_all.dat tmp/29004_format_2010051320100206.dat tmp/29004_in.pipe tmp/29004_index_201005132002.dat tmp/29004_out.pipe tmp/29222_format_2010051320105459.dat tmp/29256_wget_all.dat tmp/29278_format_2010051320103746.dat tmp/29298_wget_all.dat tmp/29376_format_2010051320102702. dat tmp/29425_format_2010051420105138.dat tmp/29498 tmp/29498_urls.dat tmp/29560_wget_all.dat tmp/29688 tmp/29795_wget_all.dat tmp/29883_format_2010051320102249.dat tmp/29980_format_2010051320101752.dat tmp/30092_format_2010051220103915.dat tmp/30092_in.pipe tmp /30092_out.pipe tmp/3012_format_2010051420100008.dat tmp/3012_in.pipe tmp/3012_index_201005141300.dat tmp/3012_out.pipe tmp/30277_format_2010051320105549.dat tmp/30277_in.pipe tmp/30277_index_201005131455.dat tmp/30277_out.pipe tmp/30291_wget_all.dat tmp /30423_format_2010051320101950.dat tmp/30426_format_2010051420102425.dat tmp/30495 tmp/30495_urls.dat tmp/30557_wget_all.dat tmp/30571_wget_all.dat tmp/30577_wget_all.dat tmp/30586 tmp/30586_urls.dat tmp/30690 tmp/30690_urls.dat tmp/30756_wget_all. dat tmp/30794 tmp/30794_urls.dat tmp/30815_format_2010051320102722.dat tmp/30874 tmp/30874_urls.dat tmp/30886_format_2010051320100253.dat tmp/30886_in.pipe tmp/30886_out.pipe tmp/308_wget_all.dat tmp/30967_wget_all.dat tmp /31056_format_2010051320102100.dat tmp/31072 tmp/31072_urls.dat tmp/3111_wget_all.dat tmp/3122_wget_all.dat tmp/31271_format_2010051320102341.dat tmp/31279_format_2010051320105603.dat tmp/31279_in.pipe tmp/31279_index_201005131456.dat tmp/31279_out.pipe tmp/31303_wget_all.dat tmp/31312_format_2010051420102717.dat tmp/31349_format_2010051320101230.dat tmp/31470_wget_all.dat tmp/315 tmp/31502 tmp/31502_urls.dat tmp/31512_format_2010051320102403.dat tmp/31546 tmp/31546_urls.dat tmp/31566_wget_all.dat tmp/31612_wget_all.dattmp/31709_wget_all.dat tmp/31742_format_2010051320105256.dat tmp/31742_in.pipe tmp/31742_out.pipe tmp/31750_format_2010051320102415.dat tmp/3193 tmp/31975_wget_all.dat tmp/32143_wget_all.dat tmp/32165_format_2010051420103018.dat tmp/32281_format_2010051320105706.dat tmp /32281_in.pipe tmp/32281_index_201005131457.dat tmp/32281_out.pipe tmp/32293_format_2010051320102508.dat tmp/32552_wget_all.dat tmp/32638_format_2010051320101141.dat tmp/32651 tmp/32651_urls.dat tmp/32652 tmp/32652_urls.dat tmp/32711 tmp/32711_urls. dat tmp/32713_wget_all.dat tmp/32718_wget_all.dat tmp/3327_format_2010051420103756.dat tmp/3327_in.pipe tmp/3327_index_201005141237.dat tmp/3327_out.pipe tmp/3347 tmp/3380 tmp/3399_format_2010051320100256.dat tmp/3399_in.pipe tmp /3399_index_201005131502.dat tmp/3399_out.pipe tmp/339_format_2010051320102413.dat tmp/339_in.pipe tmp/339_out.pipe tmp/3435_format_2010051420103608.dat tmp/3486 tmp/3486_urls.dat tmp/3497 tmp/3497_urls.dat tmp/3549_wget_all.dat tmp/ 3563_wget_all.dat tmp/3568_format_2010051420100301.dat tmp/3568_in.pipe tmp/3568_index_201005141503.dat tmp/3568_out.pipe tmp/3583_format_2010051420100301.dat tmp/3583_in.pipe tmp/3583_index_201005141503.dat tmp/3583_out.pipe tmp/3679_wget_all.dat tmp/ 3693_format_2010051320105326.dat tmp/3693_in.pipe tmp/3693_out.pipe tmp/3716 tmp/3716_urls.dat tmp/3717 tmp/3765_format_2010051320100049.dat tmp/3778_wget_all.dat tmp/3788 tmp/3869_format_2010051320101214.dat tmp/3890_format_2010051320105702.dat tmp /3890_in.pipe tmp/3890_index_201005131857.dat tmp/3890_out.pipe tmp/3923_format_2010051420105842.dat tmp/3923_in.pipe tmp/3923_index_201005141058.dat tmp/3923_out.pipe tmp/3951_wget_all.dat tmp/3961_wget_all.dat tmp/3991_wget_all.dat tmp /3992_wget_all.dat tmp/400_format_2010051320104557.dat tmp/4077_format_2010051320100134.dat tmp/4081_format_2010051320104423.dat tmp/4089_wget_all.dat tmp/4108_wget_all.dat tmp/4113_wget_all.dat tmp/4122_format_2010051320101240.dat tmp/4169 tmp/4205_format_2010051320102516.dat tmp/4299_wget_all.dat tmp/4334 tmp/4358_format_2010051420100053.dat tmp/4358_in.pipe tmp/4358_index_201005141300.dat tmp/4358_out.pipe tmp/4385_format_2010051320100209.dat tmp/4494_format_2010051220104042.dat tmp/4494_in.pipe tmp/4494_out.pipe tmp/4497_format_2010051320100324.dat tmp/ 4497_in.pipe tmp/4497_index_201005131503.dat tmp/4497_out.pipe tmp/4513_format_2010051420100907.dat tmp/469_wget_all.dat tmp/4768 tmp/4768_urls.dat tmp/4830_wget_all.dat tmp/4865_formatDef.dat tmp/4865_format_2010051220103554.dat tmp/494_format_2010051420100555. dat tmp/494_in.pipe tmp/494_index_201005141105.dat tmp/494_out.pipe tmp/4968_format_2010051220103619.dat tmp/4968_in.pipe tmp/4968_out.pipe tmp/5033_urls.dat tmp/5067_format_2010051320105600.dat tmp/5067_in.pipe tmp/5067_index_201005131656. dat tmp/5067_out.pipe tmp/5104_format_2010051220103649.dat tmp/5104_in.pipe tmp/5104_out.pipe tmp/5229_format_2010051320104445.dat tmp/5373_urls.dat tmp/5458_urls.dat tmp/5592_format_2010051320100337.dat tmp/5592_in.pipe tmp/5592_index_201005131503. dat tmp/5592_out.pipe tmp/5672_urls.dat tmp/5728 tmp/5728_urls.dat tmp/5826 tmp/5826_urls.dat tmp/5883_wget_all.dat tmp/5995 tmp/5995_urls.dat tmp/6026_format_2010051220104053.dat tmp/6026_in.pipe tmp/6026_out.pipe tmp/6126 tmp/6126_urls.dat tmp/6195 tmp/6195_urls.dat tmp/6222 tmp/6259 tmp/6259_urls.dat tmp/6389_format_2010051420103617.dat tmp/6389_in.pipe tmp/6389_index_201005141236.dat tmp /6389_out.pipe tmp/6489 tmp/6489_urls.dat tmp/6552_wget_all.dat tmp/6566_format_2010051320102812.dat tmp/6603_format_2010051320104222.dat tmp/6701_wget_all.dat tmp/6799_format_2010051320102911.dat tmp/6832_format_2010051220104130.dat tmp/6832_in.pipe tmp/6832_out.pipe tmp/7269 tmp/7535_format_2010051420104705.dat tmp/7535_in.pipe tmp/7535_index_201005141047.dat tmp/7535_out.pipe tmp/7635_wget_all.dat tmp/7795_format_2010051320103750.dat tmp/7831 tmp/8038_format_2010051420100101.dat tmp/8038_in.pipe tmp/8038_index_201005142001. dat tmp/8038_out.pipe tmp/8042_format_2010051320104421.dat tmp/8042_in.pipe tmp/8042_index_201005131644.dat tmp/8042_out.pipe tmp/8064 tmp/8064_urls.dat tmp/8100 tmp/8100_urls.dat tmp/8126_wget_all.dat tmp /8142_format_2010051320103851.dat tmp/8158_wget_all.dat tmp/8163_wget_all.dat tmp/8203_wget_all.dat tmp/8225 tmp/8345_format_2010051320103540.dat tmp/8363_format_2010051320103928.dat tmp/8368_wget_all.dat tmp/8621_format_2010051420100801.dat tmp/8621_in.pipe tmp/8621_index_201005141508.dat tmp/8621_out.pipe tmp/8654_format_2010051320103956.dat tmp/8780_format_2010051420101101.dat tmp/8844_format_2010051320103916.dat tmp/8844_in.pipe tmp/8844_index_201005131539.dat tmp/8844_out.pipe tmp/8875_format_2010051320101620.dat tmp/8875_in.pipe tmp/8875_index_201005131516.dat tmp/8875_out.pipe tmp/8886 tmp/8953_format_2010051320104033.dat tmp/9019_format_2010051420104240.dat tmp/9019_in.pipe tmp/9019_index_201005141242.dat tmp/9019_out.pipe tmp/9126 tmp/9126_urls.dat tmp/916_wget_all.dat tmp/9203_format_2010051420102926. dat tmp/9231 tmp/9231_urls.dat tmp/9324 tmp/9324_urls.dat tmp/9445_wget_all.dat tmp/9462 tmp/9462_urls.dat tmp/9602_urls.dat tmp/9653_format_2010051320105322.dat tmp/9662_urls.dat tmp/9724_urls.dat tmp/9779_urls.dat tmp/9838 tmp/9838_urls.dat tmp/9883_format_2010051320104539.dat tmp/9883_in.pipe tmp/9883_index_201005131645.dat tmp/9883_out.pipe tmp/9969 tmp/9969_urls.dat tmp/articles_3532-aliens.html tmp/ ehow tmp / task.id tmp/task_45.info.10 tmp/task_45.info.11 tmp/task_45.info.12 tmp/task_45.info.13 tmp/task_45.info.14 tmp/task_45.info.15 tmp/ task_45.info.16 tmp/task_45.info.17 tmp/task_45.info.18 tmp/task_45.info.2 tmp/task_45.info.3 tmp/task_45.info.4 tmp/task_45.info.5 tmp /task_45.info.6 tmp/task_45.info.7 tmp/task_45.info.8 tmp/task_45.info.9 tmp / train
User-Agent: Mozilla/4.0 (compatible; MSIE.6.0; Windows NT 5.1)
Pragma: no-cache
Cache-Control: no-cache
Connection: close
[Blank line]
The first acts of the contents of the request the request that the server through the GET method to request resources, / http.html resource name for the request, HTTP/1.1 that use http protocol, version 1.1.The next few lines and then request information as the header (header), which describes some of the other information requested, such as the identity and so the client browser.The last blank line to indicate end of the request.
When the Web server receives the request, the server checks the validity of the requested resources, and have the appropriate permissions.If not, the server will return the http response similar to the following information:
HTTP/1.1 200 OK
Server: Microsoft-IIS/5.0
Date: Thursday, March 31, 2005 17:15:23 GMT
Content-Type: text / html
Content-Length: 88
[Blank line]
hello, http
The first line of the "200" is a status code that the server successfully completed the request, if unsuccessful will return other status codes.Content-Type that returns the data type, Content-Length, said the length of the returned data.Blank line to indicate the end of the header, the following is the browser to return upon request the data content, here is http.html the file contents, parse html source code browser, the Web page presented to the user, go here to complete a successfulhttp communication.
Above is the basis of Web communications, just like the Windows message mechanism, you may not use it, but you must know it, you have to know those things that hide what high content of low-level, so that you understand and use thosethings have advanced very big help:).
2. Html form
Previous http.html file is a simple static html pages, but as a Web program that is too simple, and it does not accept user input, always display the same content.We need to be able to return based on user input the appropriate data.
Look at the following html code:
Observe this code, which has a html form, its contents including
And between which there is a submit button (), when the user clicks the button, the browser in the html form submitted to the Web server, all the input, form tag method attribute specifies the method presented here to get, the gethttp GET request in the corresponding request method, form the input query strings are appended to the URL on the way, in the text box to enter a string, such as "form", and watch your browser's address bar, will becomeSimilar http://www.myweb.com/form.html?p=form, this is because the browser sent a such a GET request:
GET / form.html? P = form HTTP/1.1
...
...
[Blank line]
If
Tag method attribute to "post", main role is to use post method to send the browser the request, when using the post method, the user's input is not to transmit through the URL, but the content on the browser's header after a POST requestsent to the Web server:
POST / form.html HTTP/1.1
...
...
Content-Type: application / x-www-form-urlencoded
Content-Length: 6
[Blank line]
p = form
Browser will use the user input method GET or POST sent to the Web server, a process called "back fat (Postback)".This concept is important in Web applications often involves back