Switch to full style
HTML,DHTML,Javascript,XML,CSS
Post a reply

Typing Status Bar Text javascript code

Mon Oct 20, 2008 12:00 am

This JavaScript code will enable you to display text within your status bar that is typed line by line. This JavaScript provides a great way to tell your visitors about a special offer or whatever you'd like.

However, use this script cautiously, as you certainly don't want to irritate your visitors.

Place the following code between your <BODY> tags and place your lines of text where indicated in red. You may edit the typing speed by changing the text indicated in bold.

Code:
<SCRIPT language="JavaScript">
<!--
   
var current 
= 0
var x 
= 0
var speed 
= 100
var speed2 
= 100
function initArray
(n) {
this.length = n;
for (var i =1; i <= n; i++) {
this[i] = ' '
}
}
typ = new initArray(4)
typ[0]="Your First Line of Text Here"
typ[1]="Your Second Line of Text Here"
typ[2]="Your Third Line of Text Here"
typ[3]="Your Fourth Line of Text Here"
function typewrite() {
var m = typ[current]
window.status = m.substring(0, x++) + ""
if (== m.length + 1) {
= 0
current
++
if (current > typ.length - 1) {
current = 0
}
setTimeout("typewrite()", speed2)
}
else {
setTimeout("typewrite()", speed)
}
}
typewrite()
// -->
</SCRIPT>




Post a reply
  Related Posts  to : Typing Status Bar Text javascript code
 Status Bar Link Description javascript code     -  
 calculate sum of many text inputs in javascript     -  
 $2000 Per Month Typing From Home(TI ID 17507)     -  
 Javascript code with Unity3D     -  
 Preloading Images javascript code     -  
 Redirect to a New Page javascript code     -  
 First Visit Pop Up Window javascript code     -  
 Back to previous page javascript code     -  
 Reload a Window With a Button javascript code     -  
 Javascript Code For Moving Images On Click Of A Button     -  

Topic Tags

JavaScript Time