JavaScript Ticker 1.2 (IE) : Animation « GUI Components « JavaScript DHTML

JavaScript DHTML
1. Ajax Layer
2. Data Type
3. Date Time
4. Development
5. Document
6. Event
7. Event onMethod
8. Form Control
9. GUI Components
10. HTML
11. Javascript Collections
12. Javascript Objects
13. Language Basics
14. Node Operation
15. Object Oriented
16. Page Components
17. Security
18. Style Layout
19. Table
20. Utilities
21. Window Browser
Microsoft Office Word 2007 Tutorial
Java
Java Tutorial
Java Source Code / Java Documentation
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
C# / C Sharp
C# / CSharp Tutorial
ASP.Net
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
PHP
Python
SQL Server / T-SQL
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
JavaScript DHTML » GUI Components » Animation 
JavaScript Ticker 1.2 (IE)

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title>JavaScript Ticker 1.2</title>
<style type="text/css">
.link{font-family:verdana,arial,helvetica; font-size:8pt; color:#003399; font-weight:normal}
.link:hover{font-family:verdana,arial,helvetica; font-size:8pt; color:#0099FF; font-weight:normal}
.tick{font-family:verdana,arial,helvetica; font-size:10pt; color:#003399; font-weight:bold}
.tick:hover{font-family:verdana,arial,helvetica; font-size:10pt; color:#0099FF; font-weight:bold}
.header{font-family:arial,verdana,helvetica; font-size:20pt; color:#DEAC00; font-weight:bold}
</style>
<script language="javascript">
// Location of this script:
// http://www.qiksearch.com/javascripts/ticker12.htm
//*********************************************
//* JavaScript Ticker 1.2                     *
//* Ticks a number of messages                *
//* (c) Premshree Pillai,                     *
//* http://www.qiksearch.com                  *
//* E-mail : [email protected]            *
//* Use the script freely as long as this     *
//* message is intact                         *
//*********************************************

window.onerror = null;
 var bName = navigator.appName;
 var bVer = parseInt(navigator.appVersion);
 var NS4 = (bName == "Netscape" && bVer >= 4);
 var IE4 = (bName == "Microsoft Internet Explorer" 
 && bVer >= 4);
 var NS3 = (bName == "Netscape" && bVer < 4);
 var IE3 = (bName == "Microsoft Internet Explorer" 
 && bVer < 4);
 var i=0;
 var top_pos = 60;
 var left_pos = 200;
 var time_length = 2000;
 var div_name = "qiksearch";
 var ticker_msg = new Array(
     "Welcome to Qiksearch",
     "Intellisearch Bar NOW!",
     "Premshree Pillai",
     "Meta Tag Generator Online",
     "Free JavaScripts" );

 var ticker_url = new Array(
     "http://www.qiksearch.com",
     "http://intellisearch.cjb.net",
     "http://premshree.qik.cjb.net",
     "http://metataggen.qik.cjb.net",
     "http://www.qiksearch.com/javascripts.htm" );

var ticker_len = ticker_msg.length;

for(var l=0; l<ticker_len; l++)
{
document.write('<div id="' + div_name + l + '" style="position:absolute; visibility:hidden; top:' + top_pos + '; left:' + left_pos + '">' + '<table bgcolor="#000000" cellspacing="0" cellpadding="1" width="400"><tr><td><table width="100%" bgcolor="#EFEFEF"><tr><td><center><a href="' + ticker_url[l] + '" class="tick">' + ticker_msg[l'</center></a></td>');
document.write('</tr></table></td></tr></table>' + '</div>');
}

if (NS4 || IE4) {
 if (navigator.appName == "Netscape") {
 layerStyleRef="layer.";
 layerRef="document.layers";
 styleSwitch="";
 }else{
 layerStyleRef="layer.style.";
 layerRef="document.all";
 styleSwitch=".style";
 }
}

//SCROLL
function tick(){
if (NS4 || IE4) {
 if(i<ticker_len)
 {
  if(i==0)
  
   eval(layerRef+'["'+div_name+(ticker_len-1)+'"]'+
   styleSwitch+'.visibility="hidden"');
  }
  if(i>0)
  
   eval(layerRef+'["'+div_name+(i-1)+'"]'+
   styleSwitch+'.visibility="hidden"');
  }
 eval(layerRef+'["'+div_name+i+'"]'+
 styleSwitch+'.visibility="visible"');
 }
 if(i<ticker_len-1)
 {
 i++;
 }
 else
 {
 i=0;
 }
 setTimeout("tick()",time_length);
 }
}

tick();

</script>

</head>
<body bgcolor="#FFFFFF">
<center>
<span class="header">JavaScript Ticker 1.2</span>
</center>
<br><br><br>

<table align="center" width="400"><tr><td>
<font face="verdana,arial,helvetica" size="-1" color="#000000">
This is a JavaScript Ticker which ticks a number of messages like the one shown above.
You can add more messages in the array <font face="courier">ticker_msg</font>. The URL for that
message should be added to the array <font face="courier">ticker_url</font>.
<br><br>Change the position of the ticker by changing the variables <font face="courier">top_pos</font> and <font face="courier">left_pos</font>. You can change the ticker speed by changing the value of the variable <font face="courier">time_length</font>. (Here it is 2000, which means that the ticker message will change every 2000 milliseconds, i.e every seconds).
</font>

</td></tr></table>
<br>
<center><a href="mailto:[email protected]class="link">&#169 Premshree Pillai</a></center>
</body>
</html>

           
       
Related examples in the same category
1. Attack animation
2. Circle Animation
3. Right to left animation
4. Flash animation in Javascript
5. Flash animation in JavaScript: Changing style Properties
6. Animation along Straight Line
7. Animation along a Circle
8. Dancing Text (IE)
9. Type Writer effect (IE)
10. Type Writer Effect 1.1 (IE)
11. Animation: Lottery Number Picker and Statistics
12. Animation: wriggly
13. Animation: welcome message
14. Animation: trio
15. Auto lotto dip
16. Animation: snow
17. Animation: star
18. Animation: mouse doodle
19. Animation: fireworks
20. Animation: pretty
21. Animation: Random Movement
22. Lotto number draw
23. Following eyes
24. Animation: three eyes
25. Animation: eyes
26. Spot light
27. Big static eyes
28. Animation based on DIV with color flash
29. Framework for creating CSS-based animations
30. Animate dynamic element h1 tag
31. Popup window animation (fly across screen)
32. Animation on several images
33. Using the onFilterChange Event Handler
34. JavaScript Animation
35. Periodically Updating the Text Displayed by an HTML Element
36. Moving an Airplane Across a Web Page
37. Link Hint Scroller 2.0 (IE)
38. Snow animation
w___ww___.__j__a___v___a__2__s___._co__m___ | Contact Us
Copyright 2003 - 08 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.