為什么無法打開新窗口?
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>JS代碼的位置</title>
<script type="text/javascript">
?function open(){
??window.open('http://idcbgp.cn','_blank','width=100,height=100,top=10,left=10')
?}
??
</script>
</head>
<body>
<script src="js/javascript.js">
???
</script>
<form>
?<input type="button" value="按鈕,點(diǎn)我"? onclick="open()"/>
</form>
</body>
</html>
2019-07-01
open(){} ?這不需要大括號 ?是直接寫在小括號里面的
2019-06-06
定義的函數(shù)名字,不能用open,換個函數(shù)名字就好了
2019-06-04
不能使用javascript關(guān)鍵字和保留字 , open就是關(guān)鍵字 , 不能用 , 換個方法名就好了
2019-05-17
關(guān)鍵字的原因