Blink Text

How can make the text is blink in ie4?
Who is Participating?

Improve company productivity with a Business Account.Sign Up

naxConnect With a Mentor Commented:
If you don't want to use DHTML, you can use javascript like this one. First put the text in a layer.

<div id = "text1" style = "position:absolute; visibility:hidden">Put your flashing text here using the old fashion way</div>

Then, before the </body> put this:

<script language="javascript">
delay = 500;

function blink(layer) {
     vis =;
     if (vis == "visible") vis = "hidden";
     else vis = "visible"; = vis;
     tstring = "blink(\""+layer+"\")";
     setTimeout(tstring, delay);

setTimeout("blink('text1')", 500);


you can control the speed of blinking by changing the value of delay (in milliseconds).

good luck!
the <BLINK> tag only works with Netscape.
Using IE, you can use a DHTML solution: with timeouts, you periodically set the color of the text to either text color or the background color. However, I personally would refrain from using such effects, to me, they look quite annoying.
a_sameerAuthor Commented:
What can i do with DHTML ?
oops, i made a mistake!

please change all the function blink(layer) part to
function blink(layer) {
     vis = document.all[layer].style.visibility;
     if (vis == "visible") vis = "hidden";
     else vis = "visible";
     document.all[layer].style.visibility = vis;
     tstring = "blink(\""+layer+"\")";
     setTimeout(tstring, delay);

this function can also be used to blink any other layer, just change the argument of blink to the name of the layer.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.