余生

一段JS实现变色文字效果
变色文字效果 function changeColor(...
扫描右侧二维码阅读全文
17
2018/09

一段JS实现变色文字效果

演示看上面,代码在下面

<!-- js实现变色文字 -->
<div id="blink">
    <strong>
        <div align="left" style="text-align:center;">
            变色文字效果
        </div>
    </strong><strong>
    <script language="javascript"> function changeColor(){ var color="#f00|#0f0|#00f|#880|#808|#088|yellow|green|blue|gray"; color=color.split("|"); document.getElementById("blink").style.color=color[parseInt(Math.random() * color.length)]; } setInterval("changeColor()",200); </script>
    </strong>
</div>
Last modification:September 23rd, 2018 at 11:34 pm
If you think my article is useful to you, please feel free to appreciate

Leave a Comment