Click to Rate and Give Feedback
MSDN
MSDN Library
Visual Studio 2008
Visual Studio
JScript
JScript Reference
Language Reference
Methods
Methods (A-E)
 escape Method

  Switch on low bandwidth view
This page is specific to
Microsoft Visual Studio 2008/.NET Framework 3.5

Other versions are also available for the following:
JScript 8.0
escape Method

Returns an encoded String object that can be read on all computers.

function escape(charString : String) : String
charString

Required. Any String object or literal to be encoded.

The escape method returns a string value (in Unicode format) that contains the contents of charstring. All spaces, punctuation, accented characters, and any other non-ASCII characters are replaced with %xx encoding, where xx is equivalent to the hexadecimal number representing the character. For example, a space is returned as "%20".

Characters with a value greater than 255 are stored using the %uxxxx format.

z3f12b47.alert_note(en-us,VS.90).gifNote:

The escape method should not be used to encode Uniform Resource Identifiers (URI). Use encodeURI and encodeURIComponent methods instead.

Version 1

Applies To:

Tags What's this?: Add a tag
Community Content   What is Community Content?
Add new content RSS  Annotations
Processing
© 2009 Microsoft Corporation. All rights reserved. Terms of Use  |  Trademarks  |  Privacy Statement
Page view tracker