Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/swift/20.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
如何在url中使用at符号(@)?_Url_Browser_Uri - Fatal编程技术网

如何在url中使用at符号(@)?

如何在url中使用at符号(@)?,url,browser,uri,Url,Browser,Uri,例如,我遇到以下url类型:http://username:token@example.com/protected/files 我在网上搜索了这个,但没有找到我想要的东西。维基百科解释得很好: scheme:[//[user[:password]@]host[:port][/path][?query][#fragment]您的用户名:token@example.com/受保护的/文件可能看起来像和URL,但如果事实并非如此,则是因为它不包含访问数据的协议。它是一个uri 浏览器(我想您指的是we

例如,我遇到以下url类型:
http://username:token@example.com/protected/files

我在网上搜索了这个,但没有找到我想要的东西。

维基百科解释得很好:


scheme:[//[user[:password]@]host[:port][/path][?query][#fragment]
您的
用户名:token@example.com/受保护的/文件
可能看起来像和URL,但如果事实并非如此,则是因为它不包含访问数据的协议。它是一个uri


浏览器(我想您指的是web浏览器)确实与URL一起工作,URL是包含协议的URI的一个子类型。请注意,web浏览器不适用于所有现有协议,只适用于其中一些协议(http、https、ftp、文件…)
username
不是协议。

在这种情况下,最好链接到URL wiki页面@bradbury9。您是否注意到“语法”部分实际上引用了维基百科关于URI的文章,我最初链接的是哪一个?是的,但URL的描述更符合OP问题,我想我们必须同意在这一点上存在分歧。