3)html当中如何引用js文件 如果需要javascript工程师和html美工各干各的工作,需要分开写文件。 例 1.2 <html> <head> <script src="Hello.js"></script> <title></title> </head> <body> </body> </html> Hello.js(如果你用notepad建立一个txt之后你再改为js,一定在存时,要存成utf-8或unicode格式): var a ; /*before you set value, a' type can not be defined.*/ document.writeln(typeof(a) + "<br>他们"); a = true; document.writeln(typeof(a) + "<br>"); /*下面的console.log只有安装了firebug的firebox不报错*/ console.log("This is the 1 message 马克-to-win write in %s", a); document.writeln(a);
更多请见:https://blog.csdn.net/qq_44594249/article/details/98882787
本文系转载,前往查看
如有侵权,请联系 cloudcommunity@tencent.com 删除。
本文系转载,前往查看
如有侵权,请联系 cloudcommunity@tencent.com 删除。