ערוך

שתף באמצעות


Manager.CanonizeURL(String, Manager+URL_CANONFLAGS) Method

Definition

Converts a URL string into canonical form.

This API supports the product infrastructure and is not intended to be used directly from your code.

public:
 static System::String ^ CanonizeURL(System::String ^ pURL, Microsoft::IE::Manager::URL_CANONFLAGS flags);
public static string CanonizeURL (string pURL, Microsoft.IE.Manager.URL_CANONFLAGS flags);
static member CanonizeURL : string * Microsoft.IE.Manager.URL_CANONFLAGS -> string
Public Shared Function CanonizeURL (pURL As String, flags As Manager.URL_CANONFLAGS) As String

Parameters

pURL
String

A null-terminated string of maximum length (INTERNET_MAX_URL_LENGTH) that contains a URL string. If the string does not refer to a file, it must include a valid scheme such as "http://".

flags
Manager.URL_CANONFLAGS

The flags that specify how the URL will be converted to canonical form. The following flags can be combined:

  • Manager.URL_CANONFLAGS: Treat "/./" and "/../" in a URL string as literal characters, not as shorthand for navigation.

  • Manager.URL_CANONFLAGS: Convert any occurrence of "%" to its escape sequence.

  • Manager.URL_CANONFLAGS: Replace only spaces with escape sequences. This flag takes precedence over Manager.URL_CANONFLAGS, but does not apply to opaque URLs.

  • Manager.URL_CANONFLAGS: Replace unsafe characters with their escape sequences. Unsafe characters are characters that may be altered during transport across the Internet. They include the <, >, ", #, {, }, |, \, ^, [, ], and ' characters. This flag applies to all URLs, including opaque URLs.

  • Manager.URL_CANONFLAGS: Defined to be the same as Manager.URL_CANONFLAGS.

  • Manager.URL_CANONFLAGS: Combine URLs with client-defined pluggable protocols, according to the World Wide Web Consortium (W3C) specification. This flag does not apply to standard protocols such as FTP, HTTP, and Gopher. If this flag is set, there is no need to also set Manager.URL_CANONFLAGS.

  • Manager.URL_CANONFLAGS: Unescape any escape sequences that the URLs contain, with two exceptions. The escape sequences for "?" and "#" are not unescaped. If one of the URL_ESCAPE flags is also set, the two URLs are first unescaped, and then combined, and then escaped.

Returns

The canonicalized URL.

Applies to