//AMAZON FRAMEWORK FILE
var themeColor = "black";
var hideDash = true;
var customATC = false;
var customCHKOUT = false;

function removeImg(){
var AS = document.getElementsByTagName('td');
	for (i=0; i<AS.length; i++){
		if ((AS[i].width == 10) || (AS[i].width == 16)){
			AS[i].style.display = "none";
			AS[i].className = "td" + i; 
		}
	}
}
function removeDash(){
    if(hideDash){
    var noDash = document.getElementsByTagName('a');
    for (var i = 0, j = noDash.length; i < j; i++){
	    if (noDash[i].className.match(/\bn\b/))
		    { noDash[i].innerHTML = noDash[i].innerHTML.replace(/^ ?- /, ''); }
		}
	}
}
function removesub(){
    var navtab = document.getElementsByTagName("table");
    var quicktr = navtab[0].getElementsByTagName("tr");
    quicktr[1].style.display = "none";
    quicktr[1].parentNode.removeChild(quicktr[1]);
    for(var i=0; i < navtab.length; i++){
        if(navtab[i].className == "main"){
            var maintr = navtab[i].getElementsByTagName("tr");
            maintr[0].style.display = "none";
            maintr[0].parentNode.removeChild(maintr[0]);
        }
    }
    if(document.getElementById("footernav")){
        var footertr = document.getElementById("footernav");
        footertr.parentNode.style.display = "none";
        var remTr = footertr.parentNode;
        remTr.parentNode.removeChild(remTr);
    }
}
function changeNav() {
	var tNav = document.getElementsByTagName("td");
	for ( var i=0; i < tNav.length; i++) {
		if (tNav[i].style.paddingLeft == "10px") {
			tNav[i].className = "sub";
		}
	}
}

// Rotating testimonials 
//JL - jeffl@solidcactus.com - Solid Cactus 

function domticker(content, divId, divClass, delay, fadethis){
	this.content=content
	this.tickerid=divId 
	this.delay=delay 
	this.mouseoverBol=0 
	this.pointer=1
	/*Need a better way for this ... */
	this.opacitystring=(typeof fadethis!="undefined")? "width: 100%; filter:progid:DXImageTransform.Microsoft.alpha(opacity=100); -moz-opacity: 1" : ""
	/* ... */
	if (this.opacitystring!="") this.delay+=500 
	this.opacitysetting=0.2 
	document.write('<div id="'+divId+'" class="'+divClass+'"><div style="'+this.opacitystring+'">'+content[0]+'</div></div>')
	var instanceOfTicker=this
	setTimeout(function(){instanceOfTicker.initialize()}, delay)
	}
	
	domticker.prototype.initialize=function(){
	var instanceOfTicker=this
	this.contentdiv=document.getElementById(this.tickerid).firstChild 
	document.getElementById(this.tickerid).onmouseover=function(){instanceOfTicker.mouseoverBol=1}
	document.getElementById(this.tickerid).onmouseout=function(){instanceOfTicker.mouseoverBol=0}
	this.rotatemsg()
	}
	
	domticker.prototype.rotatemsg=function(){
	var instanceOfTicker=this
	if (this.mouseoverBol==1) 
	setTimeout(function(){instanceOfTicker.rotatemsg()}, 100)
	else{
	this.fadetransition("reset") 
	this.contentdiv.innerHTML=this.content[this.pointer]
	this.fadetimer1=setInterval(function(){instanceOfTicker.fadetransition('up', 'fadetimer1')}, 100) 
	this.pointer=(this.pointer<this.content.length-1)? this.pointer+1 : 0
	setTimeout(function(){instanceOfTicker.rotatemsg()}, this.delay) 
	}
	}
	
	domticker.prototype.fadetransition=function(fadetype, timerid){
	var contentdiv=this.contentdiv
	if (fadetype=="reset")
	this.opacitysetting=0.2
	if (contentdiv.filters && contentdiv.filters[0]){
	if (typeof contentdiv.filters[0].opacity=="number") 
	contentdiv.filters[0].opacity=this.opacitysetting*100
	else 
	contentdiv.style.filter="alpha(opacity="+this.opacitysetting*100+")"
	}
	else if (typeof contentdiv.style.MozOpacity!="undefined" && this.opacitystring!=""){
	contentdiv.style.MozOpacity=this.opacitysetting
	}
	else
	this.opacitysetting=1
	if (fadetype=="up")
	this.opacitysetting+=0.2
	if (fadetype=="up" && this.opacitysetting>=1)
	clearInterval(this[timerid])
}