Salve a tutti!
Recentemente ho scaricato, proprio da questo sito, lo script per avere il testo scorrevole nella statusbar.
Mi chiedevo, e se invece nella statusbar volessi una scritta fissa anzichè scorrevole? Come posso fare?
Grazie in anticipo, ecco qui lo script che avevo scaricato per chi fosse interessato:
=====================
<html>
<head>
<script language="JavaScript">
<!--
var scrtxt="Script scaricato da www.mrwebmaster.it";
var lentxt=scrtxt.length;
var width=100;
var pos=1-width;
function scorrevole() {
pos++;
var scroller="";
if (pos==lentxt) {
pos=1-width;
}
if (pos<0) {
for (var i=1; i<=Math.abs(pos); i++) {
scroller=scroller+" ";}
scroller=scroller+scrtxt.substring(0,width-i+1);
}
else {
scroller=scroller+scrtxt.substring(pos,width+pos);
}
window.status = scroller;
setTimeout("scorrevole()",150);
}
//-->
</script>
</head>
<body onLoad="scorrevole();return true;">
<h1>Status bar: Testo scorrevole</h1>
<p>
Per vedere il codice sorgente dello script clicca su: Visualizza > HTML<br><br>
Script scaricato da <a href="https://www.mrw.it" target="_blank">Mr.Webmaster</a><br><br>
Se ti piace questo script e pensi che ti sia stato utile ti chiediamo, per favore, di inserire sul tuo sito un link a Mr.Webmaster
</p>
</body>
</html>
Recentemente ho scaricato, proprio da questo sito, lo script per avere il testo scorrevole nella statusbar.
Mi chiedevo, e se invece nella statusbar volessi una scritta fissa anzichè scorrevole? Come posso fare?
Grazie in anticipo, ecco qui lo script che avevo scaricato per chi fosse interessato:
=====================
<html>
<head>
<script language="JavaScript">
<!--
var scrtxt="Script scaricato da www.mrwebmaster.it";
var lentxt=scrtxt.length;
var width=100;
var pos=1-width;
function scorrevole() {
pos++;
var scroller="";
if (pos==lentxt) {
pos=1-width;
}
if (pos<0) {
for (var i=1; i<=Math.abs(pos); i++) {
scroller=scroller+" ";}
scroller=scroller+scrtxt.substring(0,width-i+1);
}
else {
scroller=scroller+scrtxt.substring(pos,width+pos);
}
window.status = scroller;
setTimeout("scorrevole()",150);
}
//-->
</script>
</head>
<body onLoad="scorrevole();return true;">
<h1>Status bar: Testo scorrevole</h1>
<p>
Per vedere il codice sorgente dello script clicca su: Visualizza > HTML<br><br>
Script scaricato da <a href="https://www.mrw.it" target="_blank">Mr.Webmaster</a><br><br>
Se ti piace questo script e pensi che ti sia stato utile ti chiediamo, per favore, di inserire sul tuo sito un link a Mr.Webmaster
</p>
</body>
</html>