亚洲在线久爱草,狠狠天天香蕉网,天天搞日日干久草,伊人亚洲日本欧美

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

會做的大神,幫忙找下錯,謝謝

<!DOCTYPE html>

<html>

<head>

? ? <meta charset="UTF-8">

? ? <title>實踐題 - 選項卡</title>

? ? <style type="text/css">

? ? ?/* CSS樣式制作 */?

? ? ?/*格式化樣式*/

? ? body,ol,table,tr,td,dt,dd,dl,h1,h2,h3,h4,h5,h6,form,input,select,textarea{margin:0;padding:0; font-family:"微軟雅黑"; font-size:14px; color:#444; font-weight:normal;}

ul,li{margin:0;padding:0; font-family:"微軟雅黑";font-weight:normal;}?

? ? ul li{list-style-type: none;}

? ? ?/*代碼樣式*/

? ? #tab{width: 500px; height: 260px; background-color: #f7f7f7; border: 1px solid #eee; margin: 100px auto;}

? ? #tab ul{ ? ?height: 36px; width: 100%; clear: both; border-bottom: 1px solid #eee;}

? ? #tab ul li{float: left; width: 90px; text-align: center; line-height: 36px; color: #444444; border-right: 1px solid #EEEEEE; text-decoration: none;}

? ? #tab ul li:hover{color:red}

? ? .on{color: red !important;}

? ??

? ? #box{width: 460px; margin: auto; line-height: 28px;}

? ? .hide{display: none;}

? ??

? ? </style>

? ? <script type="text/javascript">

? ? window.onload = function(){

? ? ? ?var bhx=document.getElementById("tab");

? ? ? ?var bhy=bhx.getElementsByTagName("ul")[0];

? ? ? ?var bhz=bhy.getElementsByTagName("li");

? ? ? ?var bgdiv=bhx.getElementsByTagName("div");

? ? ? ?

? ? ? ?var len=bhz.length

? ? ? ?for(var i=0; i<len;i++){

? ? ? ? bhz[i].index=i;

? ? ? ? bhz[i].onclick = function(){

? ? ? ? for(var n=0; n<len; n++){

? ? ? ? bhz[n].className = "";

? ? ? ? ? ? ? ? bgdiv[n].className = "hide";

? ? ? ? }

? ? ? ? this.className = "on";

? ? ? ? bgdiv[this.index].className = "";

? ? ? ? }

? ? ? ?};

? ? }?

? ? </script>

</head>

<body>

<!-- HTML頁面布局 -->

<div id="tab">

<ul>

<li>房產</li>

<li>家居</li>

<li>二手房</li>

</ul>

<div id="box">

<div style="display: block;">

<p>275萬購昌平鄰鐵三居 總價20萬買一居

? ?200萬內購五環三居 140萬安家東三環

? ?北京首現零首付樓盤 53萬購東5環50平

? ?京樓盤直降5000 中信府 公園樓王現房</p>?

</div>

<div>

<p> ?40平出租屋大改造 美少女的混搭小窩

? ? 經典清新簡歐愛家 90平老房煥發新生

? ? 新中式的酷色溫 66平撞色活潑家居

? ? 瓷磚就像選好老婆 衛生間煙道的設計</p>

</div>

<div>

<p>

通州豪華3居260萬 二環稀缺2居250w甩

? ? 西3環通透2居290萬 130萬2居限量搶購

? ? 黃城根小學學區僅260萬 121平70萬拋!

? ? 獨家別墅280萬 蘇州橋2居優惠價248萬

</p>

</div>

</div>

</div>

</body>

</html>


正在回答

1 回答

找到了

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

舉報

0/150
提交
取消

會做的大神,幫忙找下錯,謝謝

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

購課補貼
聯系客服咨詢優惠詳情

幫助反饋 APP下載

慕課網APP
您的移動學習伙伴

公眾號

掃描二維碼
關注慕課網微信公眾號