<!-- Beginning of JavaScript -

// CREDITS:
// Right-To-Left-Scroller width fade-effect by Urs Dudli and Peter Gehrig 
// Copyright (c) 2000 Peter Gehrig and Urs Dudli. All rights reserved.
// Permission given to use the script provided that this notice remains as is.
// Additional scripts can be found at http://www.24fun.com.
// info@24fun.ch
// 6/7/2000

// IMPORTANT: 
// If you add this script to a script-library or script-archive 
// you have to add a link to http://www.24fun.com on the webpage 
// where the scrips will be running.

// CONFIGURATION:
// Go to www.24fun.com, open category 'text' and download 
// the full-version of this script as ZIP-file containing
// step-by-step instructions for non-programmers.

// Edit the variables below:



	// Your messages. Add as many as you like
var message=new Array()

// the URLs of your messages
var messageurl=new Array()


message[0]="   New Bus,  New Service,  New Era.   Welcome to the Hunter Valley Buses Website.  "




messageurl[0]="http://service.bfast.com/bfast/click?bfmid=7279965&siteid=30125004&bfpage=javascript"

// the targets of the links
// accepted values are '_blank' or '_top' or '_parent' or '_self'
// or the name of your target-window (for instance 'main')
var messagetarget="_blank"

// font-color
var messagecolor= "red"

// distance of the scroller to the left margin of the browser-window (pixels)
var scrollerleft=130

// distance of the scroller to the top margin of the browser-window (pixels)
var scrollertop=75

// width of the scroller (pixels)
var scrollerwidth=515

// height of the scroller (pixels)
var scrollerheight=57

// speed 1: lower means faster
var pause=30

// speed 2: higher means faster
var step=2

// font-size
var fntsize=12


// font-family
var fntfamily="Arial"

// font-weight: 1 means bold, 0 means normal
var fntweight=1

// do not edit the variables below
var clipleft,clipright,cliptop,clipbottom
var i_message=0
var timer
var textwidth
var textcontent=""
if (fntweight==1) {fntweight="700"}
else {fntweight="100"}


function init() {

	gettextcontent()

    if (document.all) {
		marqueetext.innerHTML=textcontent
		textwidth=marqueetext.offsetWidth
		document.all.marqueetext.style.posTop=scrollertop
        document.all.marqueetext.style.posLeft=scrollerleft+scrollerwidth
	
		clipleft=0
		clipright=0
		cliptop=0
		clipbottom=scrollerheight
		document.all.marqueetext.style.clip ="rect("+cliptop+" "+clipright+" "+clipbottom+" "+clipleft+")"
        scrolltext()
    }
    if(!document.all && document.getElementById){
		document.getElementById("marqueetext").style.document.write(textcontent)
		document.getElementById("marqueetext").style.document.close()
		textwidth=document.getElementById("marqueetext").style.document.width
		document.getElementById("marqueetext").style.posTop=scrollertop
        document.getElementById("marqueetext").style.posLeft=scrollerleft+scrollerwidth
	
		document.getElementById("marqueetext").style.left=0
		document.getElementById("marqueetext").style.right=0
		document.getElementById("marqueetext").style.top=0
		document.getElementById("marqueetext").style.bottom=scrollerheight
        scrolltext()
    }
	if (document.layers) {
		document.marqueetext.document.write(textcontent)
		document.marqueetext.document.close()
		textwidth=document.marqueetext.document.width
		document.marqueetext.top=scrollertop
		document.marqueetext.left=scrollerleft+scrollerwidth
	
		document.marqueetext.clip.left=0
		document.marqueetext.clip.right=0
		document.marqueetext.clip.top=0
		document.marqueetext.clip.bottom=scrollerheight

        scrolltext()
    }

}

function scrolltext() {
    if (document.all) {
		if (document.all.marqueetext.style.posLeft>=scrollerleft-textwidth) {
			document.all.marqueetext.style.posLeft-=step
			clipright+=step
			if (clipright>scrollerwidth) {
				clipleft+=step
			}
			document.all.marqueetext.style.clip ="rect("+cliptop+" "+clipright+" "+clipbottom+" "+clipleft+")"
			
			var timer=setTimeout("scrolltext()",pause)
		}
		else {
			changetext()
		}
	}
	if(!document.all && document.getElementById){
		if (document.getElementById("marqueetext").style.posLeft>=scrollerleft-textwidth) {
			document.getElementById("marqueetext").style.posLeft-=step
			document.getElementById("marqueetext").style.clip.right+=step
			if (document.getElementById("marqueetext").style.clip.right>scrollerwidth) {
				document.getElementById("marqueetext").style.left+=step
			}
			var timer=setTimeout("scrolltext()",pause)
		}
		else {
			changetext()
		}
	}
   if (document.layers) {
		if (document.marqueetext.left>=scrollerleft-textwidth) {
			document.marqueetext.left-=step
			document.marqueetext.clip.right+=step
			if (document.marqueetext.clip.right>scrollerwidth) {
				document.marqueetext.clip.left+=step
			}
			var timer=setTimeout("scrolltext()",pause)
		}
		else {
			changetext()
		}
	}
}

function changetext() {
    i_message++
	if (i_message>message.length-1) {i_message=0}
	gettextcontent()
	if (document.all) {
		marqueetext.innerHTML=textcontent
		textwidth=marqueetext.offsetWidth
		
        document.all.marqueetext.style.posLeft=scrollerleft+scrollerwidth
		clipleft=0
		clipright=0
		document.all.marqueetext.style.clip ="rect("+cliptop+" "+clipright+" "+clipbottom+" "+clipleft+")"
		
        scrolltext()
	}
	if(!document.all && document.getElementById){
		document.getElementById("marqueetext").style.innerHTML=textcontent
		textwidth=document.getElementById("marqueetext").style.offsetWidth
		
        document.getElementById("marqueetext").style.left=scrollerleft+scrollerwidth
		document.getElementById("marqueetext").style.left=0
		document.getElementById("marqueetext").style.right=0		
        scrolltext()
	}
	if (document.layers) {
   		document.marqueetext.document.write(textcontent)
		document.marqueetext.document.close()
		textwidth=document.marqueetext.document.width

		document.marqueetext.left=scrollerleft+scrollerwidth
		document.marqueetext.clip.left=0
		document.marqueetext.clip.right=0
		
        scrolltext()
	}
}

function gettextcontent() {
	textcontent="<span class=\'redtext\' style=\'position:relative;font-size:"+fntsize+"pt;font-family:"+fntfamily+";font-weight:"+fntweight+"\'>"
	textcontent+="<nobr><img src=\'/graphics/bus.gif\' STYLE=\'position:relative; left:0; top:10\'>"
	textcontent+=""+message[i_message]+"</nobr></span>"
}



// - End of JavaScript --->