// Highlighter Scroller II script- By JavaScript Kit (http://www.javascriptkit.com)
// For this and over 400+ free scripts, visit http://www.javascriptkit.com/
// This notice must stay intact

//CONFIGURE MESSAGES AND VARIABLES
var tickercontents=new Array()
tickercontents[0]='<font color="red"><b><a href="http://www.elliottwave.com/a.asp?url=/club/default.aspx?aid=2818&dy=ccga&cn=7bit" target="blank">Investing - Download the Independent Investor eBook, FREE!</a></font>'
tickercontents[1]='<font color="red"><b><a href="http://www.elliottwave.com/a.asp?url=/club/default.aspx?aid=3748&dy=ccga&cn=7bit" target="blank">Trading - The Most Important Investment Report You will Read in 2008</a></font>'
tickercontents[2]='<font color="red"><b><a href="http://www.elliottwave.com/a.asp?url=/club/default.aspx?aid=2688&dy=ccga&cn=7bit" target="blank">Trading - How to Use Bar Patterns to Spot Trade Setups</a></font>'
tickercontents[3]='<font color="red"><b><a href="http://www.elliottwave.com/a.asp?url=/club/default.aspx?aid=3984&dy=ccga&cn=7bit" target="blank">Trading - Secrets to Preserving Wealth in Recession</a></font>'
tickercontents[4]='<font color="red"><b><a href="http://www.elliottwave.com/a.asp?url=/club/default.aspx?aid=3985&dy=ccga&cn=7bit" target="blank">Trading - How to Trade Forex With Elliott Wave</a></b></font>'
tickercontents[5]='<font color="red"><b><a href="http://www.elliottwave.com/a.asp?url=/wave/VideoCrashCourse&cn=7bit" target="blank">Education - Elliott Wave Video Crash Course</a></b></font>'
tickercontents[6]='<font color="red"><b><a href="http://www.elliottwave.com/a.asp?url=/wave/tutorialclub/&cn=7bit" target="blank">Education - Elliott Wave Tutorial</a></b></font>'
tickercontents[7]='<font color="red"><b><a href="http://www.elliottwave.com/a.asp?url=/info/default.aspx&cn=7bit" target="blank">Education - Elliott Wave Principle</a></b></font>'
tickercontents[8]='<font color="red"><b><a href="http://www.rupeemail.in/rupeemail/invite.do?in=NTMwNTUlIyVhYk1VRmNxSWY4bkhlbVhEeHlSZGw0b3ox" target="blank">Get Paid To Open & Read The Contents Of Rupee Mail</a></font>'

var tickerwidth="600px"
var tickerheight="25px"
var fontcss="font: color:black"
var tickdelay=5000 //delay btw messages
var highlightspeed=5 //2 pixels at a time.
var highlightcolor="#FFFFFF"
var backdroptextcolor="#FFFFFF"

////Do not edit pass this line////////////////

document.write('<style>#highlighterbg a{color:'+backdroptextcolor+'}</style>')
document.write('<div style="position:relative;left:0px;top:0px; width:'+tickerwidth+'; height:'+tickerheight+';'+fontcss+'">')
document.write('<span id="highlighterbg" style="position:absolute;left:0;top:0;color:'+backdroptextcolor+'; width:'+tickerwidth+'; height:'+tickerheight+';padding: 4px"></span><span id="highlighter" style="position:absolute;left:0;top:0;clip:rect(auto auto auto 0px); background-color:'+highlightcolor+'; width:'+tickerwidth+';height:'+tickerheight+';padding: 4px"></span>')
document.write('</div>')

var currentmessage=0
var clipbottom=1

function changetickercontent(){
msgheight=clipbottom=crosstick.offsetHeight
crosstick.style.clip="rect("+msgheight+"px auto auto 0px)"
crosstickbg.innerHTML=tickercontents[currentmessage]
crosstick.innerHTML=tickercontents[currentmessage]
highlightmsg()
}

function highlightmsg(){
//var msgheight=crosstick.offsetHeight
if (clipbottom>0){
	clipbottom-=highlightspeed
	crosstick.style.clip="rect("+clipbottom+"px auto auto 0px)"
	beginclip=setTimeout("highlightmsg()",20)
}
else{
	clipbottom=msgheight
	clearTimeout(beginclip)
	if (currentmessage==tickercontents.length-1) currentmessage=0
		else currentmessage++
			setTimeout("changetickercontent()",tickdelay)
	}
}

function start_ticking(){
	crosstickbg=document.getElementById? document.getElementById("highlighterbg") : document.all.highlighterbg
	crosstick=document.getElementById? document.getElementById("highlighter") : document.all.highlighter
	crosstickParent=crosstick.parentNode? crosstick.parentNode : crosstick.parentElement
	if (parseInt(crosstick.offsetHeight)>0)
		crosstickParent.style.height=crosstick.offsetHeight+'px'
	else
		setTimeout("crosstickParent.style.height=crosstick.offsetHeight+'px'",100) //delay for Mozilla's sake
	changetickercontent()
}

if (document.all || document.getElementById)
	window.onload=start_ticking
