asp.net.ph

Server.UrlDecode Method

System.Web Namespace   HttpServerUtility Class


Decodes a string encoded for HTTP transmission and sent to the server in a URL.

Overload List

1. URL-decodes a string and returns the decoded string.

2. Decodes an HTML string received in a URL and sends the resulting output to a TextWriter output stream.


Example

The following example decodes the string named EncodedString ( received in a URL ) into the string named DecodedString.

NOTE: This example shows how to use one of the overloaded versions of UrlDecode. For other examples that might be available, see the individual overload topics.

[ VB ]
Dim writer As New StringWriter
Server.UrlDecode ( EncodedString, writer ) 
Dim DecodedString As String = writer.ToString ( )

[ C# ]
StringWriter writer = new StringWriter ( );
Server.UrlDecode ( EncodedString, writer );
String DecodedString = writer.ToString ( );
See Also

HttpServerUtility Members Skip Navigation Links




Home
Suggested Reading


Previous page Back to top Next page

© 2000-2010 Rey Nuñez All rights reserved.

If you have any question, comment or suggestion
about this site, please send us a note

You can help support asp.net.ph