Provide thousands of free JavaScript code examples, DHTML, HTML JavaScript Tutorials, Reference and Help. JavaScriptBank.com is the best JavaScript resources |
Over 2000+ free Javascript
at JavaScriptBank.com Website
Once the bar is done, you can specify a set of javascript actions to perform or
cause a page redirect. There is a function in the script called
action(). You simply add your javascript commands here or you can cause a
redirect to another page by adding something like:
document.location.href="http://redirect_page.html";. Currently it is set
to hide the bar and display an alert message.
You can also cause the current page to reload by adding something like:
document.location.reload(). Note: If the script is used in this way, the
current page will reload itself continuously after n seconds. This would
really only be useful for pages that have changing content like a webcam page,
or maybe a news page.
You can specify an action to take place when the bar is clicked with the mouse.
The action(s) to take place when this happens is determined by a function called
clickBar(). This can be used to cancel the timerbar if the user clicks
it. If you do not want anything to happen, just remove everything in this
function.