Vida Una Homepage
Forum Home Forum Home > Programación > Códigos JavaScript
  New Posts New Posts RSS Feed - Máquina de escribir
  FAQ FAQ  Forum Search   Events   Register Register  Login Login


Máquina de escribir

 Post Reply Post Reply
Author
Message
Programador View Drop Down
Expert@
Expert@
Avatar

Joined: 09 Mayo 2009
Location: San Pedro Alc.
Status: Offline
Points: 54
Post Options Post Options   Thanks (0) Thanks(0)   Quote Programador Quote  Post ReplyReply Direct Link To This Post Topic: Máquina de escribir
    Posted: 09 Mayo 2009 at 3:22pm

<!-- PRIMER PASO: Copiar dentro del tag BODY -->

<script language="JavaScript">
<!--
var isIE4 = (navigator.appVersion.charAt(0)>=4 && (navigator.appVersion).indexOf("MSIE") != -1);
var isNN4 = (navigator.appVersion.charAt(0)>=4 && (navigator.appName).indexOf("Netscape") != -1);
tID = 0;
i = 0;
spd  = 50;
str= "La máquina de escribir fue creada por Remington en el año 1873. Un siglo después la computadora se apoderaría del trono."
function typeLayer() {
 if(i >  str.length){
  clearTimeout(tID);
 } else {
  msg = str.substring(0,i);
  if(isNN4 == true){
   document.layers['layer1'].document.write('<font face="Arial" color="#004080">'+msg.fontsize(2)+'</font>');
   document.layers['layer1'].document.close();
  }
  if(isIE4 == true){
   layer1.innerHTML = '<strong><font face="Arial" color="#004080">'+msg.fontsize(2)+'</font></strong>';
  }
  i++;
  tID = setTimeout("typeLayer()",spd);
 }
}
//-->
</script>
<span id="layer1" style="position: absolute; left: 10px; top: 20px"></span>

<!-- SEGUNDO PASO: Copiar dentro del tag BODY -->

<body onload="typeLayer()" onunload="clearTimeout(tID)">

Back to Top
Sponsored Links


Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down



This page was generated in 0.438 seconds.