// JavaScript Document

// Popup scripts
function openPopupWin(e)
{
	var el = e.target || e.srcElement;
	if(!el.tagName){return;};
	while(el.tagName.toLowerCase()!="a")
	{
		if(!el.parentNode){return;};
		el = el.parentNode;
		if(!el.tagName){return;};
	};

	if(el.className=="popupjs_r")
	{
		yui.Event.stopPropagation(e);
		yui.Event.preventDefault(e);
		window.open(el.href,"popup","resizable=1,modal=1,width=450,height=590,top=20,left=200");
		return false;
	};
	if(el.className=="popupjs_w")
	{
		yui.Event.stopPropagation(e);
		yui.Event.preventDefault(e);
		window.open(el.href,"popup","resizable=1,modal=1,width=600,height=515,top=20,left=200");
		return false;
	};
	if(el.className=="popupjs_c")
	{
		yui.Event.stopPropagation(e);
		yui.Event.preventDefault(e);
		window.open(el.href,"popup","resizable=1,modal=1,width=450,height=625,top=20,left=200");
		return false;
	};
	if(el.className=="popupjs_finish_w")
	{
		yui.Event.stopPropagation(e);
		yui.Event.preventDefault(e);
		window.open(el.href,"popup","resizable=1,modal=1,width=600,height=380,top=20,left=200");
		return false;
	};
};
yui.Event.addListener(document, "click",openPopupWin);	
