Page

How to make a label blink

//Java Script

<script type="text/javascript">

        function doBlink() {

            var blink = document.all.tags("BLINK")

            for (var i = 0; i < blink.length; i++)

                blink.style.visibility = blink.style.visibility == "" ? "hidden" : ""

        }

        function startBlink() {

            if (document.all) setInterval("doBlink()", 500)

        }

        window.onload = startBlink;

    </script>



//CSS

    <style type="text/css">

        blink

        {

            -webkit-animation-name: blink;

            -webkit-animation-iteration-count: infinite;

            -webkit-animation-timing-function: cubic-bezier(1.0,0,0,1.0);

            -webkit-animation-duration: 1s;

        }

    </style>



//HTML

 <span style="color: Red; font-size: 11px; font-family: Times New Roman;">

 <blink>New!</blink>

 </span>



No comments:

Post a Comment