Ver Mensaje Individual
  #1 (permalink)  
Antiguo 22/09/2005, 09:08
Avatar de AJVEvoluzione
AJVEvoluzione
 
Fecha de Ingreso: agosto-2004
Ubicación: Buenos Aires
Mensajes: 195
Antigüedad: 19 años, 8 meses
Puntos: 1
Exclamación Ayuda con TypeWriter

Hola! consegui este efecto de escritura pero solo funciona en Explorer, Opera , Netscape pero no en Mozilla Firefox, si alguien me lo remienda por favor Muchas gracias por su ayuda


Código:
<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<title></title>
<style type="text/css">

BODY{

	margin-top: 0px;
    margin-left: 0px;
    margin-right: 0px;
    margin-bottom: 0px;
background-attachment: fixed;
background-repeat: repeat;
background-position: 0 0;
}
</style>
</head>

<body onload="typeLayer()" onunload="clearTimeout(tID)" topMargin="0" bgcolor="#E8E8E8" background="back.JPG">
<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  = 40; 
str= " Hola! esta es la maquina de escribir<br>Bienvenidos a mi sitio web, Texto de prueba, 1234 Texto - Texto de prueba, 1234 Texto "
function typeLayer() {
 if(i >  str.length){
  clearTimeout(tID);
 } else {
  msg = str.substring(0,i);
  if(isNN4 == true){
   document.layers['layer1'].document.write('<font color=#000000 font face=Times New Roman font weight= bold font-size= 12pt>'+msg+'</font>');
   document.layers['layer1'].document.close();
  }
  if(isIE4 == true){
   layer1.innerHTML = '<font color=#000000 font face=Times New Roman font weight= bold font-size= 12pt>'+msg+'</font>';
  }
  i++;
  tID = setTimeout("typeLayer()",spd);
 }
}
//-->
</script>


<table border="0" width="100%" height="100%" cellspacing="0" cellpadding="0">
  <tr>
    <td width="100%" valign="bottom" align="right">
    </td>
  </tr>
</table>

<p><span id="layer1"
style="LEFT: 140px; RIGHT: 140px; POSITION: absolute; TOP: 40px; color: rgb(0,0,0); font-family: Times New Roman; font-size: 12pt; font-weight: bold"></span>
</p>
<!--webbot bot="HTMLMarkup" startspan TAG="XBOT" --></SCRIPT><!--webbot bot="HTMLMarkup" endspan
-->
<script>
if (!document.layers)
document.write('<div id="divStayTopLeft" style="position:absolute">')
</script>
<layer id="divStayTopLeft">

</body>
</html>