Re: [問題] 如何得知訊窗元件裡的資訊
※ 引述《bennylu (Benny)》之銘言:
: ※ 引述《terrybob (翔翔)》之銘言:
: : <div id="LayerBull" class="Bulletin">....(asp程式所產生的表格)...</div>
: : 因為表格有高度有寬度
: : 我想知道…怎麼樣才可以得知那個表格的高度?…
: : 我在script下…
: : alert(window.document.body.LayerBull.top);
: : 或
: : alert(window.document.body.Bulletin.top);
: : 兩個都沒任何回應…= =
: : 請教教我吧…> <
: <script>
: alert(document.getElementById('LayerBull').style.top);
: </script>
剛剛的推文問題,找到原因了
因為我的css樣式表是用連結的…↓
<link href="1.css" rel="stylesheet" type="text/css">
= =如果css設定是在網頁中的話,而不是連結css樣式表裡,就可以讀到…
有辦法讀到樣式表裡的資料嗎? > <"
抱歉,問題多…
↓網頁中的id ↓樣式表中的
<div id="LayerBull" class="Bulletin">....(asp程式所產生的表格)...</div>
請大家幫忙…感謝~(敬禮)
--
自戀:26.42% 狗血:21.25% 愛:17.54%
超合金:11.85% 心中的翡翠森林:8.57% 燃燒的小宇宙:6.99%
渣渣:6.86% 反動思想:0.53%
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 218.211.4.196
推
08/25 11:32, , 1F
08/25 11:32, 1F
推
08/25 11:51, , 2F
08/25 11:51, 2F
討論串 (同標題文章)