SPHttpUtility.UrlPathEncode-Methode (String, Boolean, Boolean, Boolean)
Codiert Pfadteil einer URL für die zuverlässige HTTP-Übertragung vom Webserver an einen Client.
Namespace: Microsoft.SharePoint.Utilities
Assembly: Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Syntax
'Declaration
Public Shared Function UrlPathEncode ( _
urlToEncode As String, _
allowHashParameter As Boolean, _
encodeUnicodeCharacters As Boolean, _
rfcCompliant As Boolean _
) As String
'Usage
Dim urlToEncode As String
Dim allowHashParameter As Boolean
Dim encodeUnicodeCharacters As Boolean
Dim rfcCompliant As Boolean
Dim returnValue As String
returnValue = SPHttpUtility.UrlPathEncode(urlToEncode, _
allowHashParameter, encodeUnicodeCharacters, _
rfcCompliant)
public static string UrlPathEncode(
string urlToEncode,
bool allowHashParameter,
bool encodeUnicodeCharacters,
bool rfcCompliant
)
Parameter
urlToEncode
Typ: System.StringDer URL zu codieren.
allowHashParameter
Typ: System.BooleanTrue, um die Hash-Parameter zulassen. andernfalls False.
- encodeUnicodeCharacters
Typ: System.Boolean
rfcCompliant
Typ: System.BooleanMachen die URL-Codierung mit RFC 3986-fähig? Legen sie auf True, außer Legacycode Kompatibilität.
Rückgabewert
Typ: System.String
Der codierte URL. Leer, wenn der UrlToEncode-Parameter ist empty und null, wenn der UrlToEncode-Parameter null ist.