self.name = 'roadbase';
function wimpyButtonTrackStarted(myFile_in){
   alert("Now Playing: " + myFile_in);
}
function changeMainContent(section,content){
	thispath = '/dashboard/dispatch.php?section='+section+'&'+content;
	alert(thispath);
	ajax_loadContent('main_content',thispath);
}
// SHOW HIDE DIV LAYERS
// style="display:none;"
function HideContent(d) {
	document.getElementById(d).style.display = "none";
}

function ShowContent(d) {
	document.getElementById(d).style.display = "block";
}
function HideContentDisplay(d) {
	document.getElementById(d).style.display = "none";
}

function ShowContentDisplay(d) {
	document.getElementById(d).style.display = "block";
}

function ReverseContentDisplay(d) {
	if(document.getElementById(d).style.display == "none") { document.getElementById(d).style.display = "block"; }
	else { document.getElementById(d).style.display = "none"; }
}

function reloadNavigationBlock(block){
	ajax_loadContent(block,'/includes/ajax/navigation.ajax.php?block='+block);
}

/* Use for the normal SQUARE buttons */
function changeButtonColor(divid_link,when){
	if(when == 'over'){
		cur_class = document.getElementById(divid_link).className
		document.getElementById(divid_link).className = 'nav_button_on';
	} else {
		document.getElementById(divid_link).className = cur_class;
	}
}

// checkUncheckAll(this);
function checkUncheckAll(theElement) {
	
     var theForm = theElement.form, z = 2;
	 for(z=2; z<theForm.length;z++){
      if(theForm[z].type == 'checkbox' && theForm[z].name != 'checkall'){
	  theForm[z].checked = theElement.checked;
	  }
     }
}
function checkUncheckAll_1(theElement,idx) {
	
     var theForm = theElement.form, z = 1;
	 for(z=1; z<theForm.length;z++){
      if(theForm[z].type == 'checkbox' && theForm[z].name != 'checkall'){
	  theForm[z].checked = theElement.checked;
	  }
     }
}
// checkUncheckAllByDiv(this,'divid');
function checkUncheckAllByDiv(theElement,divid) {
	 var boxes = document.getElementById(divid).getElementsByTagName("input"), z = 1;
	 for(z=1; z<boxes.length;z++){
      if(boxes[z].type == 'checkbox' && boxes[z].name != 'checkall'){
	  boxes[z].checked = theElement.checked;
	  }
     }
}


function displayWindow(url, width, height, resizable, scrollbars, menubar, status, screenX, screenY, left, top) {
	var Win = window.open(url,"displayWindow3",'width=' + width + ',height=' + height + ',resizable=' + resizable + ',scrollbars=' + scrollbars + ',menubar=' + menubar + ',status=' + status + ',left=' + left + ',top=' + top + ',screenX=' + screenX + ',screenY=' + screenY + '' );
}


/* Trigger Div Fade */
function fadeDivContent(divid){
	if($(divid).length){
		setTimeout("beginFadeDivContent('"+divid+"')",3000);
	}
}
/* Begin Fading of Div */
function beginFadeDivContent(divid){
	if($(divid).length){
		NLBfadeBg(divid,'#f8f8f8','#008000','6000');
		setTimeout("hideDivContent('"+divid+"')",6000);
	}
}
/* Hide Div */
function hideDivContent(divid){
	if($(divid).length){
		new Effect.Fade($(divid));
	}
}
function updateSearchBox(keyword){
	if(keyword == ''){
		$('frmGlobalSearch').keyword.value = 'Search / Keyword';
		$('frmGlobalSearch').keyword.styleName = 'textinput_search';
	} else if (keyword == 'Search / Keyword'){
		$('frmGlobalSearch').keyword.value = '';
		$('frmGlobalSearch').keyword.styleName = 'textinput';
	}
}

function viewBio(ArtistId){
	path ='/cart/include/artistBio.php?ArtistId='+ArtistId;
	jQuery.facebox(function() {
      jQuery.get(path, function(data) {
        jQuery.facebox(data)
      })
    })
}

