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

為了賬號安全,請及時綁定郵箱和手機立即綁定

重置函數(shù)有對話框,但是點擊確定后不起作用。

<!DOCTYPE html>

<html>

<head>

<meta charset="utf-8">

<title>mission</title>

<style type="text/css">

body {

font-size: 12;

}

#txt {

height: 333px;

width: 500px;

border: red solid 2px;

padding: 5px;

}

p {

line-height: 20px;

text-indent: 2em;

}

</style>

</head>

<body>

<h1 id="demo1">JavaScript</h1>


<div id="txt">

<h5>我也不知道這要干嘛</h5>

<p>7.Your rejection taught me courage.</p>

<p>8.Whether you view me as a hero or a villain,</p>

<p>9.please know that I poured every emotion,every bit of passion and my entire self into being a Laker,</p>

</div>

<form>

<input type="button" value="改變顏色" onclick="changeColor()" />

<input type="button" value="改變寬高" onclick="ser.changeSize()" />

<input type="button" value="隱藏內(nèi)容" onclick="ser.hideText()" />

<input type="button" value="顯示內(nèi)容" onclick="ser.showText()" />

<input type="button" value="取消設置" onclick="ser.OffSet()" />

</form>


<script type="text/javascript">

var txt = document.getElementById("txt");


function changeColor() {

txt.style.color = "goldenrod";

txt.style.backgroundColor = "blanchedalmond";

}

var ser = {

changeSize: function() {

txt.style.width = "600px";

txt.style.height = "200px";

},

hideText: function() {

txt.style.display = "none";

},

showText: function() {

txt.style.display = "block";

},

OffSet: function() {

var message = confirm("你確定要重置所有設置么?");

if (message == true) {

txt.removeAttribute('style');

}

}

}

</script>

</body>

</html>


正在回答

2 回答

謝了,可能是瀏覽器問題,開始用的Google不行,換了IE就可以。

0 回復 有任何疑惑可以回復我~

代碼沒問題呀。運行也可以的噠。

0 回復 有任何疑惑可以回復我~

舉報

0/150
提交
取消

重置函數(shù)有對話框,但是點擊確定后不起作用。

我要回答 關注問題
微信客服

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

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動學習伙伴

公眾號

掃描二維碼
關注慕課網(wǎng)微信公眾號