URL(Uniform Resource Locator)

A Uniform Resource Locator (URL), colloquially termed a web address,[1] is a reference to a web resource that specifies its location on a computer network and a mechanism for retrieving it. A URL is a specific type of Uniform Resource Identifier (URI),[2][3] although many people use the two terms interchangeably.[4][a] URLs occur most commonly to reference web pages (http), but are also used for file transfer (ftp), email (mailto), database access (JDBC), and many other applications.

Most web browsers display the URL of a web page above the page in an address bar. A typical URL could have the form http://www.example.com/index.html, which indicates a protocol (http), a hostname (www.example.com), and a file name (index.html).

在WWW上,每一信息资源都有统一的且在网上唯一的地址,该地址就叫URL(Uniform Resource Locator,统一资源定位符)。URL由4部分组成:协议、主机、端口、路径。

URL(Uniform Resource Locator)地址用于描述一个网络上的资源,基本格式如下
schema://host[:port#]/path…/[?query-string]
schema: 协议(例如:http,https,ftp等等)
host:       HTTP服务器的IP地址或者域名(本机就是localhost或者127.0.0.1)
port#:      HTTP服务器的默认端口是80,这种情况下端口号可以省略,如果使用了别的端口,必须指明,例如
                  http://www.cnblog.com:8080/               
path:        访问资源的路径
query-string:发送给Web服务器的数据

发布了341 篇原创文章 · 获赞 87 · 访问量 22万+

猜你喜欢

转载自blog.csdn.net/qq_35865125/article/details/104325440