// JavaScript Document

function printAD(url, _link, width, height) {
	if(url == "") return false;
	var _t = url.substring(url.lastIndexOf(".")+1).toLowerCase();
	var _html = null;
	if(_t == "swf"){
		_html =	"<object classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0\" width=\""+ width +"\" height=\""+ height +"\">"+
				"	<param name=\"movie\" value=\""+ url +"\" />"+
				"	<param name=\"quality\" value=\"high\" />"+
				"	<embed src=\""+ url +"\" quality=\"high\" pluginspage=\"http://www.macromedia.com/go/getflashplayer\" type=\"application/x-shockwave-flash\" width=\""+ width +"\" height=\""+ height +"\"></embed>"+
				"</object>";
	}else{
		if(_link == "") _link="javascript:void(0);";
		_html = "<a href=\""+ _link +"\" target=\"_blank\"><img src=\""+ url +"\" width=\""+ width +"\" height=\""+ height +"\" border=0/></a>"
	}
	document.write(_html);
}


function $(elementId){
	return document.getElementById(elementId);
}

function showObj(oCase, oID) {
	if(oCase == null || $(oCase) == null) {
		return false;
	}
	var oItem = $(oCase).getElementsByTagName("div");
	var oNum = oItem.length;
	for(var i=0; i<oNum; i++) {
		oItem[i].style.display = "none";
	}
	if(oID != null && $(oID) != null) {
		$(oID).style.display = "";
	}
}

var prevL;
function showLabel(lID) {
	var l = $(lID);
	if(prevL != null && prevL == lID) return false;
	
	var cObj = $(l.getAttribute("cent"));
	l.className = "check";
	cObj.style.display = "";
	
	if(prevL != null) {
		var pObj = $(prevL);
		var pcObj = pObj.getAttribute("cent");
		pcObj = $(pcObj);
		pObj.className = "";
		pcObj.style.display = "none";
	}
	
	prevL = lID;
}
function changeCode() {
    $('checkCodeImg').src='ValidateCode.aspx?'+Math.random();
}
var wload="";
window.onload = function() {
	eval(wload);
}