URL and Resource

Source: Internet
Author: User

A lot of software is simple. Just like learning addition, it is natural to think about it... you can think that the old man is stupid enough, or how hard it is to unify a standard...

  • URL syntax
  • URL shortcuts
  • Common and interesting solutions

Note: The URL is Uri, unless urn occupies the world, or you can read the code written by Virgo, or you are a Virgo...

URL syntax

  As an object-oriented programmer, the syntax is a fixed class. Some need set, and some can choose set ..... of course, it is understood as a standard, a constraint, and an interface. Of course, it is not a question to select a preferred method, however, it takes a lot of money to let others understand/parse the URL as you think .....
Although each solution has its own unique syntax, in most cases, they are composed of the following nine parts, which may be all or partially

<Scheme>: // <user >:< password >@< host >:< port >/< path >;< Params>? <Query >#< frag>
Solution: // User: password @ host: Port/path; parameter? Query # Segment

  

Solution: protocol, which has the default port and gives more meaning to the whole URL. The URL is completely exposed as a "Syntax", which is user-friendly and case-insensitive.
Username/password: there is also a security mechanism in the small syntax
HOST: IP address, domain name, or other things that can represent IP Address
Port Number: In most cases, each solution has its own default port number.
Path: it can be a real path, a comparison, a translation, a resolution path, or a URL subject content, I have done some web projects and should understand what the path can represent. It's too much.
Parameter: input parameter. I want to express it as configuration information, that is, the path parameter.
Query: A common Parameter
Fragment: It is internally digested and will not be transmitted to the server. The client keeps playing... it is actually an anchor object.

This is basically the case, where punctuation is also necessary. If you want to apply for a solution, you 'd better pick a few of your favorite ones. Of course, if you have a better sorting method/idea, you can call the relevant department :)

Basically, we can see that this is a URL. Next we will look at it. It is purely a hobby or a food abuse question :)
For example, the username and password rules are related to how to parse the rules and transfer key characters. Of course, it doesn't matter if you do not know these things. They have long been completed by the framework you used, although the URL has been encapsulated, it seems that you can understand it.
Let's talk about the troubles I 've encountered. When I uploaded data in that year, I couldn't wear a parameter like # nbxx... I think you must know the reason :)

String Parsing

As a universal portable Text object (programmed), a URL means that it must be securely and reliably recognized, so using a universal US-ASCII (7 bytes) is also an inevitable situation, as for the excess part, of course, you have to rely on transcoding. Of course, for some keywords, if you do not want him to implement his own functions, transfer is also necessary (emphasize again to see what the passing parameter name = A # BC can receive --)

Common and interesting solutions

HTTP: Most people still rely on this product to know the URL...
FTP: a protocol older than HTTP
POP/POP3: Select on Foxmail
TELNET: When a hacker learns
Nfs/HDFS: file management system. Are you familiar with it?
SVN: It won't be used any more --
Javascript: Enter Javascript in your browser: Alert (1); void 0; try :). Does it feel like it is the principle of firebug implementation? :)
In short, there are more similar things, And the URL is so simple.

Summary

1. a URL consists of about 9 parts.
2. As a general-purpose format, the URL is transmitted in ASCII format. For extended characters and keywords, both need to be transferred.
3. Key characters are reserved and restricted characters.

 

URL and Resource

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.