為什么把script放在body外面會有“x”呀?
為什么把script放在body外面會有“x”呀?
<!DOCTYPE HTML>
<html>
? ? <head>
? ? ? ? <meta http-equiv="Content-Type" content="text/html; charset=gb18030">
? ? ? ? <title>插入js代碼</title>
? ? </head>
? ? <body>
? ? </body>
? ? <script type="text/javascript">
? ? ? ? document.write("開啟旅!");
? ? </script>
</html>
2019-10-08
js代碼位置是在<head></head>或者<body></body>標簽中