作者HZYSoft (pcman.ptt.cc)
看板PCman
标题[释疑] 跟大家说明一下关於网址
时间Fri Jan 16 21:27:22 2004
之前的版本一直都没有支援大写的网址,其实是因为没想到有人会用大写
因为网址好好的本来就是小写的,干麻有人故意要打大写? 所以没去管大写
事实上,依照原本的标准,网址应该要是小写才对,所以本来也不该用大写
但是查询过标准文件之後发现,上面还是标明了,虽然网址是小写,负责解读网址
的程式要有点弹性,把大写也当作小写,也就是也要允许 HTTP 的使用,虽然
照本来的规定确实应该是小写http才对,但是我刚刚又查了标准文件
其中有明文要求相关程式要把大写当成小写处理,所以下一版一定会支援大写的 HTTP
有兴趣的网友参阅相关文件 ftp://ftp.rfc-editor.org/in-notes/rfc1738.txt
(我这里节录重点部份: 节录自 RFC1738 standard 重点我标上黄色)
2.1. The main parts of URLs
A full BNF description of the URL syntax is given in Section 5.
In general, URLs are written as follows:
<scheme>:<scheme-specific-part>
A URL contains the name of the scheme being used (<scheme>) followed
by a colon and then a string (the <scheme-specific-part>) whose
interpretation depends on the scheme.
Scheme names consist of a sequence of characters. The lower
case letters "a"--"z", digits, and the characters plus ("+"), period
("."), and hyphen ("-") are allowed. For resiliency, programs
interpreting URLs should treat upper case letters as equivalent to
lower case in scheme names (e.g., allow "HTTP" as well as "http").
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 140.129.59.3
※ 编辑: HZYSoft 来自: 140.129.59.3 (01/16 21:29)