Home » DHTML » Article
DHTML Javascript Ticker
|
| Article by: | Premshree Pillai (8/28/2002) |
|
| Sponsored by: | FindMyHosting - Web Hosting Search |
| Summary: | This is a JavaScript Ticker which ticks a number of messages like the one shown above. It also has a useful 'Show All' feature. |
|
| Viewed: 38348 times |
Rating (164 votes): |
|
3.1 out of 5 |
|
|
|
DHTML Javascript Ticker
This is a JavaScript Ticker which ticks a number of messages like the one shown above. You can add more messages in the array ticker_msg. The URL for that message should be added to the array ticker_url.
Change the position of the ticker by changing the variables top_pos and left_pos. You can change the ticker speed by changing the value of the variable time_length. (Here it is 1000, which means that the ticker message will change every 1000 milliseconds, i.e every 1 second).
New in Version 1.3 : In this version the new additions are the "List All" and "Speed" buttons.
The "List All" button will list all the news items that appear in the ticker, together.
Using the "Speed" button you can change the speed of ticking. When you click on the "Speed" button 5 options will appear. When you click on any one of these, the ticker speed will change to that value.
|
|
View highlighted Comments
User Comments on 'DHTML Javascript Ticker'
|
|
|
Posted by :
Archive Import (Rikki Love) at 12:25 on Tuesday, December 10, 2002
|
I have been looking for something exactly like this for several days now. I have been trying to teach myself some coding, which teaching is yourself is a slow process. I would like to say thank you for offering this to just up and coming code writters such as myself.
| |
|
|
Posted by :
Archive Import (Whatever) at 12:10 on Monday, February 24, 2003
|
hey Premshree keep up the gud work...this is jus amazin
| |
|
|
Posted by :
Archive Import (sol8air) at 19:07 on Thursday, June 26, 2003
|
It doesn't work, missing a "]" somewhere and damned if I have time to scour every line to find a missing "]"
| |
|
|
Posted by :
Scotgig at 10:44 on Wednesday, February 04, 2004
|
Easy to resolve;
Simply replace lines 50 & 51 (the 2nd and 3rd 'document.write' lines with the following:
[quote]
document.write('<td align="right"><table class="tickerFX1" cellspacing="0" cellpadding="0" onclick="'&"tickerFX_listAll('all_news_div'); hideLayer('change_speed_div')"&'" title="List All News"><tr><td align="middle">LIST ALL</td></tr></table></td>');
document.write('<td align="right"><table class="tickerFX2" cellspacing="0" cellpadding="0" onclick="'&"tickerFX_changeSpeed('change_speed_div'); hideLayer('all_news_div')"&'" title="Change Ticker Speed"><tr><td align="middle">SPEED</td></tr></table></td>');
[/quote]
That should do the trick.
Javascript doesn't like quotation nesting.
| |
Posted by :
kraker at 00:14 on Monday, May 17, 2004
|
Is there an easy way to not make this a absolute positioning? Once you set the positioning good for one resolution, it will be totally off for a different one. Can you use percentages or put the actual code in the spot that you want the ticker to appear so you don't have to use positioning at all?
| |
|
To post comments you need to become a member. If you are already a member, please log in .
| RELATED ARTICLES |
Creating CSS Buttons by Thomas D. Greer
With Cascading Style Sheets, you can turn ordinary hyperlinks into fully functional "buttons", without using JavaScript. |
 |
DHTML Horizontal Scroller by Premshree Pillai
Scroll text horizontally when the user hovers over a link. |
 |
DHTML Javascript Ticker by Premshree Pillai
This is a JavaScript Ticker which ticks a number of messages like the one shown above. It also has a useful 'Show All' feature. |
 |
Manipulate Scrollbar Colors Using CSS and JavaScript by Mike Thompson
The thing about the default color of scrollbars is that it's dull and ugly -- usually this color is gray. Wouldn't it be nice to change this color to better fit the overall theme of your site? Luckily, Cascading Style Sheets and JavaScript can be used to do just that!
|
 |
Simple Thumbnail Browsing Solution by Troy Wolf
This simple script allows the user to select from several thumbnail images and view the larger image, using a mixture of DHTML and Cascading style sheets. |
 |
DHTML News Bar by Premshree Pillai
This is the News Bar script which displays a number of messages and rotates them using DHTML. |
 |
DHTML Scrolling Image by Premshree Pillai
Using this script the user can scroll an image left or right by clicking a buttong
|
 |
DHTML Zoom In and Out Script by Premshree Pillai
Using zoOom, you can zoom in and zoom out any image that is specified in the code.
|
 |
Simple Mouse Trail using VB Script by Jeff Anderson
With IE gaining in prominence every day, it's becoming acceptable to use VBScript in web pages. That makes some activities like the mouse trail a real cinch. |
 |
Mouse Trail with Text by Jeff Anderson
A Classic Mouse Trail Script, with configurable text, rather than images. We chose `I love you` for our text - what will you chose? |
 |
| |