<html>
<head>
<script type="text/javascript">
function blinklink()
{
if (!document.getElementById('message').style.color)
{
document.getElementById('message').style.color="red"
}
if (document.getElementById('message').style.color=="red")
{
document.getElementById('message').style.color="black"
}
else
{
document.getElementById('message').style.color="red"
}
timer=setTimeout("blinklink()",200)
}
function stoptimer()
{
clearTimeout(timer)
}
</script>
</head>
<body onload="blinklink()">
<div id="message" >Message</div>
</body>
</html>
Js 实现字体闪烁
最新推荐文章于 2023-07-18 08:29:46 发布