第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號(hào)安全,請(qǐng)及時(shí)綁定郵箱和手機(jī)立即綁定

為什么我這樣寫百度首頁(yè)出不來???

<html>

<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<title>window.open</title>

<script type="text/javascript">

? function window.open(){

? ?'http://www.baidu.com/','_blank','width=600,hieght=400,top=100px,left=0px ' ?


?}?

</script>

</head>

<body>

? ? <input name="button" type="button" onClick="window.open()" value="點(diǎn)擊我,打開新窗口!" / >

</body>

</html>


正在回答

1 回答

?function?window.open(){
???'http://www.baidu.com/','_blank','width=600,hieght=400,top=100px,left=0px?'??

?}

函數(shù)名不要取JS的關(guān)鍵字,也不能帶點(diǎn)。我估計(jì)你是把函數(shù)和方法弄混了。

修改后的代碼

<html>
<head>
<meta?http-equiv="Content-Type"?content="text/html;?charset=utf-8"?/>
<title>window.open</title>
<script?type="text/javascript">
??function?Wopen(){
???window.open('http://www.baidu.com/','_blank','width=600,hieght=400,top=100px,left=0px?');??

?}?
</script>
</head>
<body>
????<input?name="button"?type="button"?onClick="Wopen()"?value="點(diǎn)擊我,打開新窗口!"?/?>
</body>
</html>

你看下有什么不懂的

0 回復(fù) 有任何疑惑可以回復(fù)我~
#1

Bill0123 提問者

非常感謝perona大神 (*^__^*) 嘻嘻……
2015-08-03 回復(fù) 有任何疑惑可以回復(fù)我~
#2

Perona 回復(fù) Bill0123 提問者

不是大神,都是童鞋,童鞋~~~
2015-08-03 回復(fù) 有任何疑惑可以回復(fù)我~
#3

加油兮兮 回復(fù) Perona

請(qǐng)問“函數(shù)名不要取JS的關(guān)鍵字,也不能帶點(diǎn)。”這句話是說“function window.open()”這句不能跟著window.open嗎?
2015-10-17 回復(fù) 有任何疑惑可以回復(fù)我~
#4

Perona 回復(fù) 加油兮兮

是噠,function后面帶的是函數(shù)名。window.open()是方法。函數(shù)名是自定義的,方法名是本身就有的。
2015-10-18 回復(fù) 有任何疑惑可以回復(fù)我~
查看1條回復(fù)

舉報(bào)

0/150
提交
取消

為什么我這樣寫百度首頁(yè)出不來???

我要回答 關(guān)注問題
微信客服

購(gòu)課補(bǔ)貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動(dòng)學(xué)習(xí)伙伴

公眾號(hào)

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號(hào)