首页 > 代码库 > JavaScript之转义字符

JavaScript之转义字符

image

<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="Generator" content="EditPlus?">
  <meta name="Author" content="">
  <meta name="Keywords" content="">
  <meta name="Description" content="">
  <title>Document</title>
</head>
<body>
   <script type="text/JavaScript">
   document.write("some\" characters");
   document.write("i am \b an apple.");
   document.write("i am \f a new page.");
   document.write("i am \n a new line.");
   document.write("i am \r a enter.");
   document.write("i am a \x43");
   document.write("i am a \u0044");
   </script>
</body>
</html>

JavaScript之转义字符