Link to home
Start Free TrialLog in
Avatar of khanzada19
khanzada19

asked on

Blinking text on Web Page

i need blinking text on web page, i got this by using below mentioned script only when i use <blink> tags within html in Internet Explorer, but if picked the data along with tags from database it would not work. but firefox works perfeclty well in both conditions, i have PHP and MySQL and i have all menu items in database. could some one help me to get the desire


<SCRIPT>
function doBlink() {
// Blink, Blink, Blink...
var blink = document.all.tags("BLINK")
for (var i=0; i < blink.length; i++)
blink[i].style.visibility = blink[i].style.visibility == "" ? "hidden" : ""
}
function startBlink() {
// Make sure it is IE4
if (document.all)
setInterval("doBlink()",400)
}
window.onload = startBlink;
</SCRIPT>
Avatar of Rok-Kralj
Rok-Kralj
Flag of Slovenia image

CSS:
<style type="text/css">
<!--
p#blinking {text-decoration: blink;}
-->
</style>

HTML:
<p id="blinking"><a href="mailto:email@domain.com">Email me</a></p>
Easy-to-test solution:

<span style="text-decoration: blink;">Can you see me?</span>
Avatar of contactkarthi
have a look at here

http://www.rgagnon.com/jsdetails/js-0098.html

you can set the frequency to blink also
Avatar of khanzada19
khanzada19

ASKER

Dear Rok & karthi

i got ur reply and thanx for this, but my problem is windows internet explorer, ur code and mine both works very well in firefox, but nothing blinking in windows internet explorer, i have these lines in database for example i have <blink>test</blink> or ur code <span style="text-decoration: blink;">Can you see me?</span> also, those lines works with firefox etc. but not with windows internet explorer
http://www.berkery.nl/stuff/blink.php

<!--[if IE]>
<script type="text/JavaScript">
function doIt(){
document.getElementById('blink').style.visibility =  (document.getElementById('blink').style.visibility == "hidden") ? "visible" : "hidden";
}
function Knipper(){
setInterval('doIt()',1000);
}
window.onload = Knipper;
</script>
<![endif]-->

<p>Ik wil <span id="blink">knipperende tekst!</span></p>
ASKER CERTIFIED SOLUTION
Avatar of Rok-Kralj
Rok-Kralj
Flag of Slovenia image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial