function SwitchLanguage(lanid)
{
	document.frames("USER_POST_IFRAME").window.location = "../../../common/UserOpera.asp?reload=1&lanid="+lanid;
}
function PutShopping(id,num)
{
	document.frames("USER_POST_IFRAME").window.location = "../../../common/UserOpera.asp?shoppingid="+id+"&shoppingnum="+num;
}
function logout()
{
	document.frames("USER_POST_IFRAME").window.location = "../../../common/UserOpera.asp?reload=1&logout=1"
}

function SwitchColumn(id,menutype,newwindow,url)
{
	var tg = "";
	if (newwindow==1)
	{
		tg = "_blank"
	}
	if(newwindow ==2)
	{
		tg = "_self"
	}
	if(url.indexOf("http://")==-1 && url!='null') url = "http://"+url
	switch (menutype)
	{
	case 1: 
		window.open("SinglePage.asp?menuid="+id,tg,"")
		break;
	case 2:
		window.open("NewsPage.asp?menuid="+id,tg,"")
		break;
	case 3:
		window.open("ProPage.asp?menuid="+id,tg,"")
		break;
	case 4:
		window.open("FormPage.asp?menuid="+id,tg,"")
		break;
	case 5:
		window.open("guestbook.asp?username=m"+id+"&menuid="+id,tg,"")
		break;
	case 6:
		if(url!='null') window.open(url,tg,"")
		break;
	case 7:
		window.open("download.asp?menuid="+id,tg,"")
		break;
	default:
		window.open("shopPage.asp?menuid="+id,tg,"")
		break;
	}
}
function SwitchCol(id)
{
	var ln = location.href;
	var s = ln.indexOf("columnid=")
	var t = ln.substring(s,ln.length);
	ln = ln.substring(0,s+9)
	s = t.indexOf("&")
	if(s==-1) 
		t = "";
	else
		t = t.substring(s,t.length);
	location.href=ln+id+t;

}
function correctPNG() 
{
	for(var i=0; i<document.images.length; i++)
	{
	  var img = document.images[i]
	  var imgName = img.src.toUpperCase()
	  if (imgName.substring(imgName.length-3, imgName.length) == "PNG")
	  {
	   var imgID = (img.id) ? "id='" + img.id + "' " : ""
	   var imgClass = (img.className) ? "class='" + img.className + "' " : ""
	   var imgTitle = (img.title) ? "title='" + img.title + "' " : "title='" + img.alt + "' "
	   var imgStyle = "display:inline-block;" + img.style.cssText 
	   if (img.align == "left") imgStyle = "float:left;" + imgStyle
	   if (img.align == "right") imgStyle = "float:right;" + imgStyle
	   if (img.parentElement.href) imgStyle = "cursor:hand;" + imgStyle  
	   var strNewHTML = "<span " + imgID + imgClass + imgTitle
	   + " style=\"" + "width:" + img.width + "px; height:" + img.height + "px;" + imgStyle + ";"
	  + "filter:progid:DXImageTransform.Microsoft.AlphaImageLoader"
	   + "(src=\'" + img.src + "\', sizingMethod='scale');\"></span>" 
	   img.outerHTML = strNewHTML
	   i = i-1
	  }
	}
}
function ShowPage(Message,ShowArea,Fpage,PageSize)
{

}