代码如下:
复制代码 代码示例:
<html>
<head>
<title>escape()和unescape()函数用法举例_www.jb200.com</title>
</head>
<body>
<s cript language="javas cript">
function run()
{
alert("The esacpe value is:"+escape(document.form1.input1.value));
alert("The unesacpe value is:"+unescape(escape(document.form1.input1.value)));
}
</s cript>
<form name=form1>
<input type="text" name="input1" size=20 value="12320%456">
<input type=button name=click1 value="show escape value" onclick="run()">
</form>
</body>
</html>