DHTML script
 

SimplytheBest
Scripts

ASP scripts
PERL scripts
PHP scripts
JavaScripts & Ajax
Snippets
Online scripts

Ajax, DHTML
& JavaScripts

Animation
Background
Bookmarks
Buttons
Calculators
Cookies
Data handling
E-mail
Enhancements
Forms
Image rotation
Menus
Messages
Miscellaneous
Music
Password protection
Redirection
Scrollers
Tables
Time & date
Windows

Publishers
Add script
Account login
Publisher list



 

Home > Scripts > DHTML scripts & JavaScripts > Scrollers > Multi-directional scroller

 

Multi-directional scroller script

AUTHOR: Rik Comery
TYPE: Freeware
BROWSERS: IE 5, IE 6, NS 6+, Opera 6+

With this cross browser scroller script you can change from horizontal to vertical scroll and choose to pause scroller on mouse over or to leave it running. Scroller items can be a link or plain text.

Key features:

  • Change from horizontal to vertical scroll

  • Choose to pause scroller on mouse over

  • Scroller items can be either a link or plain text

  • Can be used as a links menu scroller

  • Easy to configure


EXAMPLE


1)
Insert this script in the <HEAD> section of the page.

then copy (CTRL-C) & paste (CTRL-V)

2) Insert the onLoad event handler inside the <BODY> tag as follows:

<body onLoad="runScroller()", followed by other tags such as bgcolor, etc..

copy (CTRL-C) & paste (CTRL-V)

3) Insert the following script in the <BODY> section where you want the scroller to appear in the page. It can be positioned properly by using tables or DIV's etc.

then copy (CTRL-C) & paste (CTRL-V)

4) Define the scroller elements in this section of the script:

// the text, the url (use "none" for text without link), the frame target
Article[i] = new Array ("Welcome to PlanMagic", "http://planmagic.com", "_blank");i++ 
Article[i] = new Array ("We offer a wide range of business planning software:", "none", "");i++
Article[i] = new Array ("Business plan", "http://planmagic.com/business_plan.html", "_blank");i++

and so forth.

5) Define the orientation, the size and the style of the scroller in this section of the script:

/// SCROLLER CONFIGURATION ///
orientation = "horizontal" // Orientation of scroller (horizontal or vertical)
scrollerWidth = "350" // Width of entire scroller
scrollerHeight = "25" // Height of scroller
borderWidth = 1 // Width of border (use 0 for no border)
borderColour = "Black" // Color of scroller border
backColour = "#d7ebff" // Color of scroller background
staticColour = "#000000" // Color of scroller items that are not a link
stopScroll = 1 // Pause the scroller on mouseOver (use 0 for no.)

and so forth.


For more information you can also visit the
author's web site.


[BACK] [TOP]

 


Copyright © 1997-2009 SimplytheBest Inc. Terms of Use and Legal Disclaimer.
All copyrights are acknowledged. All rights reserved.