Important: |
---|
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist. |
This function combines a base and relative URL into a single URL. The resultant URL is canonicalized.
BOOL WINAPI InternetCombineUrl( LPCTSTR lpszBaseUrl , LPCTSTR lpszRelativeUrl , LPTSTR lpszBuffer , LPDWORD lpdwBufferLength , DWORD dwFlags );
Parameters
Value | Description |
---|---|
ICU_BROWSER_MODE | Does not encode or decode characters after "#" or "?", and does not remove trailing white space after "?". If this value is not specified, the entire URL is encoded and trailing white space is removed. |
ICU_DECODE | Converts all %XX sequences to characters, including escape sequences, before the URL is parsed. |
ICU_ENCODE_SPACES_ONLY | Encodes spaces only. |
ICU_NO_ENCODE | Does not convert unsafe characters to escape sequences. |
ICU_NO_META | Does not remove meta sequences (such as "." and "..") from the URL. |
Return Values
TRUE indicates success. FALSE indicates failure. To get extended error information, call GetLastError. Possible error values for GetLastErrorare described in the following table.
Value | Description |
---|---|
ERROR_BAD_PATHNAME | The URLs could not be combined. |
ERROR_INSUFFICIENT_BUFFER | The buffer supplied to the function was insufficient or NULL. The DWORD indicated by the lpdwBufferLengthparameter will contain the number of bytes required to hold the resultant, combined URL. |
ERROR_INTERNET_INVALID_URL | The format of the URL is invalid. |
ERROR_INVALID_PARAMETER | Bad string, buffer, buffer size, or flags parameter. |
Windows CE Remarks
The lpdwBufferLengthparameter refers to the count of characters.
Requirements
Runs on | Versions | Defined in | Include | Link to |
---|---|---|---|---|
Windows CE OS | 2.0 and later | Wininet.h | Wininet.lib |
Note This API is part of the complete Windows CE OS package as provided by Microsoft. The functionality of a particular platform is determined by the original equipment manufacturer (OEM) and some devices may not support this API.
See Also
GetLastError, InternetCanonicalizeUrl