Introduction to URL and Uri

Source: Internet
Author: User
Preface a student from a senior O & M group of QQ cannot figure out the concept and connection between URL and Uri when matching the nginx location, therefore, I wrote an article to sum up the concepts. Of course, most of the concepts are extracted by Google. If you say that you can't understand them, please don't send them. Your brother's blog is not written to people without foundation, you can't understand all the resources on uriweb, including HTML documents, images, Program Clips and even this blog I am writing are all located by a unified Resource Identifier ("Uri. For example, what is the URI of the current blog? Name = "Wang" & age = 24 the host name for storing resources. For example, if the reference URI is used, the host name is not understood as the www.haolianxi.cn fragment identifier, we will not discuss whether the relative URI does not contain any naming rules. Its path usually refers to resources on the same machine. The relative URI may contain a relative path or a fragment identifier. The relative URI in the URI example is:/home/wangzhengyi/test. php? Name = "Wang" & age = 24urlurl is the abbreviation of the uniform resource location. URL can be used to describe various information resources in a unified format, including files, server addresses, and directories. From the definition, we can see that URL is a subset of Uri. There are many types of URL format protocols (indispensable). The commonly used HTTP, FTP, SVN, and other host IP addresses and port numbers containing the resource (indispensable) Many people will say, I didn't see the IP address and port number. For example, when I access www.haolianxi.cn, I don't know what the IP address and port number are. This is because the DNS relationship is used for your convenience, A virtual host is built through a webserver such as nginx or Apache, and the specific address of the host resource mapped to the domain name and (IP + port) is implemented (optional) from the URI example, we can see that the specific address is/home/wangzhengyi/the difference between the URL and the URI. The simplest sentence is that the URL is a subset of the URI, at present, the most common form of URI is the ubiquitous location matching of urlnginx. You don't need to worry about this. Check nginx's explanation of the location command and find that the specified URL allows different configurations for different Uris.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.