// JavaScript Document
// Default JS script document included in ALL Bacera.com HTML files.

/* START roll over section */

// Roll over definitions
// ----------------------
// use: image_name[on/off]
// define src of image

arr_nextoff = new Image();
arr_nextoff.src = 'images/arr_next.gif';

arr_nexton = new Image();
arr_nexton.src = 'images/arr_next_hover.gif';

// Roll over methods
function rollover(image) {
	var imgBuffer = eval(image + "on.src");
	document[image].src = imgBuffer;
	return true;
}

function rollout(image) {
	var imgBuffer = eval(image + "off.src");
	document[image].src = imgBuffer;
	return true;
}

/* END roll over section */

/* START TICKER CODE - RISK WARNING TICKER */

var tWidth='100%';                   // width (in pixels)
var tHeight='14px';                  // height (in pixels)
var tcolour='#F1EBE4';               // background colour:
var moStop=false;                    // pause on mouseover (true or false)
var fontfamily = 'tahoma';           // font for content
var tSpeed=1;                        // scroll speed (1 = slow, 5 = fast)

// enter your ticker content here (use \/ and \' in place of / and ' respectively)
var content='Trading Contract for Difference (CFD), Forex CFD, and Derivatives products may carry high degree of risk and may result in serious financial loss.  Derivatives products trading is not suitable for everyone.  The information published on this website is intended to be used for informational purposes only and does not constitute investment advice.  For further risk warning information, please visit the risk warning page by going <a href="riskwarning.php" class="link" onmouseover="cps=0" onmouseout="cps=tSpeed">here</a>.';

// Simple Marquee / Ticker Script
// copyright 3rd January 2006, Stephen Chapman
// permission to use this Javascript on your web page is granted
// provided that all of the below code in this script (including this
// comment) is used without any alteration
var cps=tSpeed; 
var aw, mq; 
var fsz = parseInt(tHeight) - 3; 

function startticker(){
	
	if (document.getElementById) {
		var tick = '<div style="position:relative;width:'+tWidth+';height:'+tHeight+';overflow:hidden;background-color:'+tcolour+'"'; 
		
		if (moStop) tick += ' onmouseover="cps=0" onmouseout="cps=tSpeed"'; 
		
		tick +='><div id="mq" style="position:absolute;left:0px;top:0px;font-family:'+fontfamily+';font-size:'+fsz+'px;white-space:nowrap;"><\/div><\/div>'; 
		document.getElementById('ticker').innerHTML = tick; 
		mq = document.getElementById("mq"); 
		mq.style.left=(parseInt(tWidth)+600)+"px"; 
		mq.innerHTML='<span id="tx">'+content+'<\/span>'; 
		aw = document.getElementById("tx").offsetWidth; lefttime=setInterval("scrollticker()",50);
	}
} 

function scrollticker(){
	mq.style.left = (parseInt(mq.style.left)>(-100 - aw)) ?parseInt(mq.style.left)-cps+"px" : parseInt(tWidth)+600+"px";
} 
  
/* END TICKER CODE - RISK WARNING TICKER */