DIV CSS 佈局教程網

 DIV+CSS佈局教程網 >> 網頁腳本 >> JavaScript入門知識 >> 關於JavaScript >> Javascript制作閃爍的邊框
Javascript制作閃爍的邊框
編輯:關於JavaScript     
本文介紹用JS來制作閃爍的邊框,演示地址:http://www.85time.com首頁,我僅制作了一個閃爍的邊框,若想一個以上的邊框都能閃爍,可以定義多個變量,本文中,我僅定義了一個變量mydowns!
代碼如下,共有兩個文件:
文件一:mydowns.js
<!--
function flash(){
if (!document.all)
return
if (mydowns.style.borderColor=="green")
mydowns.style.borderColor="E7FFA5"
else
mydowns.style.borderColor="green"
}
setInterval("flash()", 800)
//-->
文件二:mydowns.htm
<html>
<body>
<script src=mydowns.js></script>
<table width=130 id="mydowns" style="border:1px solid green"><tr><td width="100%" lign="center">
<p style="text-indent: 0; word-spacing: 0; margin: 0" align="center"><font color="#008000" size="2">本站欄目</font>
<p style="text-indent: 0; word-spacing: 0; margin: 0" align="center">
<font size="2">
<a href="http://www.85time.com/xajh/">笑傲江湖</a>
<a href="http://www.85time.com/bbs/" target="_blank">網友論壇</a></font> <p style="text-indent: 0; word-spacing: 0; margin: 0" align="center">
<font size="2">
<a href="http://www.85time.com/engine.htm" target="_blank">實用引擎</a>
<a href="http://www.85time.com/opus/opus.htm" target="_blank">推薦作品</a></font>
<p style="text-indent: 0; word-spacing: 0; margin: 0" align="center">
<font size="2">
<a href="http://www.85time.com/gb/" target="_blank">留言板</a>
<a href="http://www.85time.com/chat/" target="_blank">聊天室</a></font></td></tr></table>
</body>
</html>

XML學習教程| jQuery入門知識| AJAX入門| Dreamweaver教程| Fireworks入門知識| SEO技巧| SEO優化集錦|
Copyright © DIV+CSS佈局教程網 All Rights Reserved