Texte défilant


<html>
<head>
<title>Texte défilant</title>
<script LANGUAGE="JavaScript">
<!--
var texte = 'Le texte à faire défiler est à mettre ici...'
var i = 0;
//sert à afficher le texte tout à fait à droite
while (i ++ < 100)
  texte = " " + texte;

var timerID = null;
var pos = 0;
var delaiScroll = 75;

function startScroll() {
  window.status = texte.substring(pos++, texte.length);
  if (pos == texte.length)
    pos = 0;
  timerID = setTimeout("startScroll()", delaiScroll);
}

function stopScroll() {
  clearTimeout(timerID);
  window.status = '';
}
//-->
</script>
</head>

<body onLoad="startScroll()" onUnLoad="stopScroll()">

<h1 align="center">Texte défilant</h1>

<hr>

</body>
</html>

retour au menu des textes défilants

 

Texte tournant en boucleRetour à la page JavaScriptTexte qui rebondit