URL URLs parsing
URL: Uniform Resource Locator, letter, number, text to be encoded
URI: Uniform Resource Identifier, string format specification
Note: URLs are a subset of URIs
-
Url.parse (urlstring, Bool,bool)
Parameter 1:url parse to object, Parameter 2: Convert Qurey to JSON object, Parameter 3: correctly parse URL without protocol (HTTP)
-
Url.format (Urlobj);
-
Url.resolve (From,to) merges two strings into a full URL address
Parameter 1: Hyperlink; parameter 2: Road
Parameter interpretation
Protocol: Protocol
Slashes: Does the "//" containing the agreement
Host:ip address or domain name or hostname
Port: Ports (default 8080 not shown)
Hostname: Host Name
Hash: Anchor Point value
Search: Query string parameters
Query: Data for HTTP, ibid.
Pathname: Access to the resource path name
Path: Resource path to access
HREF: Full URL address
QueryString
-
Querystring.stringify (OBJ,SIGN1,SIGN2)
Convert the object to the form of the query part of the URL
Parameter 1: object to convert, Parameter 2: Link (default &), Parameter 3: symbol between key and value (default =)
-
Querystring.parse (STRING,SIGN1,SIGN2,SIGN3)
Convert query string to object (deserialize)
Parameter 1:query string, Parameter 2: Linker (default &), Parameter 3: symbol between key and value (default =), Parameter 4: Number of parameters (default up to 1000, 0 means no limit)
-
Querystring.escape (String) text compilation
-
Querystring.unescape (String) decompile
Node.js:URL, QueryString Introduction