
function informationbar(){
	this.displayfreq="always"
	this.content=''
}

informationbar.prototype.setContent=function(data){
	this.content=this.content+data
	document.write('<div id="informationbar" style="top: -500px">'+this.content+'</div>')
}

informationbar.prototype.animatetoview=function(){
	var barinstance=this
	if (parseInt(this.barref.style.top)<0){
		this.barref.style.top=parseInt(this.barref.style.top)+5+"px"
		setTimeout(function(){barinstance.animatetoview()}, 0)
	}
	else{
		if (document.all && !window.XMLHttpRequest)	{
			this.barref.style.setExpression("top", 'document.compatMode=="CSS1Compat"? document.documentElement.scrollTop+"px" : body.scrollTop+"px"')
		}	else	{
			this.barref.style.top=0;
//			this.barref.style.top=parseInt(document.body.scrollTop)+"px";
//			setTimeout(function(){barinstance.animatetoview()}, 0)
		}
	}
}

informationbar.close=function(){
	document.getElementById("informationbar").style.display="none"
	if (this.displayfreq=="session")
		document.cookie="infobarshown=1;path=/"
}

informationbar.prototype.setfrequency=function(type){
	this.displayfreq=type
}

informationbar.prototype.initialize=function(){
	if (this.displayfreq=="session" && document.cookie.indexOf("infobarshown")==-1 || this.displayfreq=="always"){
		this.barref=document.getElementById("informationbar")
		this.barheight=parseInt(this.barref.offsetHeight)
//		this.barref.style.top=this.barheight*(-1)+"px"
		this.barref.style.top="0px"

		this.animatetoview()
	}
}

informationbar.prototype.MM_swapImgRestore=function() { var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc; }
informationbar.prototype.MM_preloadImages=function () { var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf('#')!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}} }
informationbar.prototype.MM_findObj=function(n, d) { var p,i,x;  if(!d) d=document; if((p=n.indexOf('?'))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x; }
informationbar.prototype.MM_swapImage=function() { var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];} }


window.onunload=function(){
	this.barref=null
}

function clickTag( sTag )	{
	document.frmWe.kwd.value = sTag;
	document.frmWe.submit();
}

function cpKwd()		{
	document.frmWe.key.value = document.frmWe.kwd.value;
}

function changSpl()	{
	if ( document.getElementById("spl").style.display == "" )
	{
		document.getElementById("spl").style.display = "none";
	} else {
		document.getElementById("spl").style.display = "";
	}
}


function showTipInto( sTaImg, sTaTit, sTaDes )	{
	Wid_showTip('<div align=left style=padding:6px;><Table border=0 width=100% bgcolor=#0076fb><tr><td><table border=0 width=100% bgcolor=#ffffff><tr><td style=padding-right:10px;><img src=http://thumb.goodfile.net/thumb.asp?siteurl='+ sTaImg +' border=0 align=left width=130 height=90 class=shot></td><td valign=top align=left>'+ sTaTit +'<br><font color=#008000>http//'+ sTaImg +'</font><br><font color=#00225b>'+ sTaDes +'</font></td></tr></table></td></tr></table></div>','',300);
}


var con = "<style type='text/css'>";
var con = con + "<!--";
var con = con + ".title{	FONT-SIZE: 0.8em; COLOR: #000000; LINE-HEIGHT: 100%;  position: relative; FONT-FAMILY: 'dotum'}";
var con = con + ".title2{	FONT-SIZE: 0.8em; COLOR: #0234b3; LINE-HEIGHT: 100%;  position: relative; FONT-FAMILY: 'dotum' }";
var con = con + "input{	FONT-SIZE: 1em; COLOR: #000000; LINE-HEIGHT: 100%;  position: relative; FONT-FAMILY: 'dotum'}";
var con = con + "A.main01:link {	font-size:1em; COLOR: #032d83; letter-spacing:-1px; FONT-FAMILY: 'dotum'; TEXT-DECORATION: none}";
var con = con + "A.main01:visited {	font-size:1em; COLOR: #0148b2; letter-spacing:-1px; FONT-FAMILY: 'dotum'; TEXT-DECORATION: none}";
var con = con + "A.main01:active {	font-size:1em; COLOR: #0148b2; letter-spacing:-1px; FONT-FAMILY: 'dotum'; TEXT-DECORATION: none}";
var con = con + "A.main01:hover {	font-size:1em; COLOR: #1190d1; letter-spacing:-1px; FONT-FAMILY: 'dotum'; TEXT-DECORATION: none}";
var con = con + "body {	margin-left: 0px;	margin-top: 0px;	margin-right: 0px;	margin-bottom: 0px; BORDER-BOTTOM: #b7c5d2 1px solid;}";
var con = con + "-->";
var con = con + "</style>";

var con = con + "<div id='spl' style='position:absolute; left:50px; top:28px; z-index:1; display:none;'><table width='272' cellpadding='0' cellspacing='0' border='1'><tr><td><table cellpadding='0' cellspacing='0' border='0' width='267' height='20' bgcolor='ffffff'>";

var con = con + "<td id='splArea'></td>";

var con = con + "</table></td></tr></table></div>";

var con = con + "<div id='spl' style='position:absolute; left:305px; top:15px; z-index:1;'><a href='javascript:changSpl();'><img src='http://widget.searchwidget.co.kr/img/arr.gif' width='11' height='7' border='0'></a></div>";


var con = con + "<table width='100%' border='0' cellspacing='0' cellpadding='0'>";
var con = con + "  <tr>";
var con = con + "    <td width='100%' height='36' background='http://widget.searchwidget.co.kr/img/bg_2.gif'><table width='100%' border='0' cellspacing='0' cellpadding='0'>";
var con = con + "      <tr>";
var con = con + "        <td width='30' height='36'><a href='http://neoclick.co.kr/?dts=uyp0Tgf6RMtPWtiMvh51TN20Y' target='_neo'><img src='http://widget.searchwidget.co.kr/img/logo.gif' width='50' height='36' border='0'/></a></td>";
var con = con + "        <td width='300'><table width='300' border='0' cellspacing='0' cellpadding='0'>";

var con = con + "        <form name='frmWe' method='post' action='" + ssUrl + "' onsubmit='return cpKwd();'>";

var con = con + "			<input type='hidden' name='key' value='" + KWD + "'>";

var con = con + "					<tr>";
var con = con + "            <td><input name='kwd' id='kwd' style='BORDER-RIGHT: #b7c5d2 1px solid; BORDER-TOP: #b7c5d2 1px solid; PADDING-LEFT: 1px; BORDER-LEFT: #b7c5d2 1px solid; WIDTH: 100%; PADDING-TOP: 5px; BORDER-BOTTOM: #b7c5d2 1px solid; HEIGHT: 14px' value='" + KWD + "' /></td>";



var con = con + "            <td width='22'><input type='image' src='http://widget.searchwidget.co.kr/img/btn_search.gif' name='Image30' width='28' height='22' border='0' id='Image30' /><img src='http://neoclick.co.kr/AppCom/SearchWidgetLog_p_v2.asp?ms=2&host="+ sHost +"&url="+ ssUrlQ +"' border='0' width='0' height='0' style='display:none;'></td>";
var con = con + "          </tr>";

var con = con + "				 </form>";

var con = con + "        </table></td>";
var con = con + "        <td width='3'><img src='http://widget.searchwidget.co.kr/img/line_02.gif' width='6' height='24' /></td>";
var con = con + "        <td width='75'><table width='75' border='0' cellspacing='0' cellpadding='0'>";
var con = con + "          <tr>";
var con = con + "            <td><a href='http://click.clickstory.co.kr/?vanilla=dXhlVGFCUDhKMThHOHNFSzNjT09qWE1GNUVpMzk3RWxsVkZ5RmFlQkpRVGladUNV&turl=http%3A%2F%2Fwww.gmarket.co.kr' target='_gmarket'><img src='http://widget.searchwidget.co.kr/img/icon_03.gif' name='Image6' width='23' height='22' border='0' id='Image6' alt='Áö¸¶ÄÏ'/></a></td>";
var con = con + "            <td><a href='http://click.clickstory.co.kr/?vanilla=QTFLTGZxOTEvSjBLSDFSVTNjT09qWE1GNUVpMzk3RWxEMUkwSktyOG9GNlNpTkZ1&turl=http%3A%2F%2Fwww.auction.co.kr' target='_auction'><img src='http://widget.searchwidget.co.kr/img/icon_07.gif' name='Image5' width='23' height='22' border='0' id='Image5' alt='¿Á¼Ç'/></a></td>";
var con = con + "            <td><a href='http://click.clickstory.co.kr/?vanilla=WEJoS1FXTzY3RE9kTCtsTjNjT09qWE1GNUVpMzk3RWxseDRWbm9DNDdSRGladUNV&turl=http%3A%2F%2Fwww.11st.co.kr' target='_11st'><img src='http://widget.searchwidget.co.kr/img/icon_06.gif' name='Image4' width='23' height='22' border='0' id='Image4' alt='11¹ø°¡'/></a></td>";
var con = con + "          </tr>";
var con = con + "        </table></td>";
var con = con + "        <td width='3'><img src='http://widget.searchwidget.co.kr/img/line.gif' width='3' height='24' /></td>";

var con = con + "        <td width='31' id='DivTag'><img src='http://widget.searchwidget.co.kr/img/img_3.gif' width='31' height='24' alt='ÃßÃµÅÂ±×'/></td>";
var con = con + "        <td width='31' id='DivAd' style='display:none;'><img src='http://widget.searchwidget.co.kr/img/img_4.gif' width='31' height='24' alt='ÃßÃµ°Ë»ö'/></td>";

var con = con + "        <td width='100%'><table width='100%' border='0' cellspacing='0' cellpadding='0'>";
var con = con + "          <tr>";

var con = con + "            <td id='divtoo'></td>";

var con = con + "					</tr>";
var con = con + "        </table></td>";
var con = con + "        <td width='100%'>&nbsp;</td>";
var con = con + " <td id='iconroll' style='PADDING-TOP: 6px;'><img src='http://widget.searchwidget.co.kr/img/B_icon_02.gif' width='31' height='24' border='0'>";
var con = con + " <td id='iconarea' width='300' align='right'><iframe src='http://widget.searchwidget.co.kr/roll/widgetdata_ytn.asp' width='300' height='36' scrollbar='no' frameborder='0' style='padding:0 0 0 0'></iframe></td>";
var con = con + "      </tr>";
var con = con + "    </table></td>";
var con = con + "  </tr>";
var con = con + "</table>";


var infobar=new informationbar()




infobar.setContent(con)

infobar.initialize()




document.write("<iframe id=\"divTool\" width=\"100%\" height=\"30\" scrollbar=\"no\"></iframe>");
document.write("<div id=\"widgettooltip\" style='position:absolute;'></div>");







//document.write("<form name=\"__BAR_\" method=\"post\" action=\"/NeovCM/NeovCGI_NeoClick.exe/NeovHandler\" target=\"frmBAR\">");
document.write("<form name=\"__BAR_\" method=\"post\" action=\"/p_query.asp\" target=\"frmBAR\">");
document.write("  <input type=\"hidden\" name=\"KWD\" value=\'"+KWD+"'>");
//document.write("  <input type=\"hidden\" name=\"KWD\" value=\''>");
document.write("	<input type=\"hidden\" name=\"CONT\">");
document.write("	<input type=\"hidden\" name=\"PT\" value=\'goodfile\'>");
document.write("  <input type=\"hidden\" name=\"BlockOption\" value=\"0\">");
document.write("</form>");





function BarView(sJson)		{
	if ( sJson.TagList.length > 0 )
	{
		document.getElementById("kwd").value = sJson.TagList[0];
	}

	if ( sJson.NeoList.length > 1 )
	{
		for (i=0; i < sJson.NeoList.length; i++)
		{
			var sBody = "<td><table border='0' cellspacing='0' cellpadding='0'>";
			var sBody = sBody + "	<tr onMouseOver='showTipInto( \""+ sJson.NeoList[i].SiteHost.replace("http://","") +"\", \""+ sJson.NeoList[i].Title +"\", \""+ sJson.NeoList[i].Description +"\");' onMouseOut='hideTip();'>";
			var sBody = sBody + "		<td width='35' height='22' border='1' bgcolor='b0b7d3'><div align='center'><img src='http://thumb.goodfile.net/thumb.asp?siteurl="+ sJson.NeoList[i].SiteHost.replace("http://","") +"' width='33' height='20'/></div></td>";
			var sBody = sBody + "		<td width='5'>&nbsp;</td>";
			var sBody = sBody + "		<td nowrap><div style='position:relative;width:100%;text-overflow:ellipsis;overflow:hidden;cursor:hand'><nobr><a href='"+ sJson.NeoList[i].ClickUrl +"' class='main01' target='_spon' alt='aaaaaaa'>" + sJson.NeoList[i].Title + "</a></nobr></div></td>";
			var sBody = sBody + "		<td width='20'>&nbsp;&nbsp;&nbsp;&nbsp;</td>";
			var sBody = sBody + "	</tr>";
			var sBody = sBody + "</table></td>";

			if ( i == 0 )
			{
				var tBody = "<table border='0' cellspacing='0' cellpadding='0'>" + sBody;
			} else	{
				var tBody = tBody + sBody;
			}

			if ( i > 3 )
			{
				break;
			}
		}
		var tBody = tBody + "</table>";

		document.getElementById("DivTag").style.display = "none";
		document.getElementById("DivAd").style.display = "";
		document.getElementById("iconroll").style.display = "none";
		document.getElementById("iconarea").style.display = "none";		
		document.getElementById("divtoo").innerHTML = tBody;		
	
	} else {
		for (i=0; i < sJson.TagList.length; i++)
		{
			var sBody = "";
			var sBody = "<td><table border='0' cellspacing='0' cellpadding='0'>";
			var sBody = sBody + "<tr>";
			var sBody = sBody + "<td width='15'><img src='http://widget.searchwidget.co.kr/img/icon_05.gif' width='13' height='13' /></td>";
			var sBody = sBody + "<td width='5'>&nbsp;</td>";

			var sBody = sBody + "<td style='padding-top:2px;' nowrap><div style='position:relative;width:100%;text-overflow:ellipsis;overflow:hidden;cursor:hand'><nobr><a href='http://www.goodfile.net/multisearch/search.asp?key="+ sJson.TagList[i] +"' class='main01'>" + sJson.TagList[i] + "</a></nobr></div></td>";
			
			var sBody = sBody + "<td width='5'>&nbsp;</td>";
			var sBody = sBody + "</tr>";
			var sBody = sBody + "</table></td>";

			var tsplArea = "";

			var tsplArea = tsplArea + "<tr onMouseOver='this.style.backgroundColor=\"#FDFAE8\"' onMouseOut='this.style.backgroundColor=\"#FFFFFF\"' style='cursor:pointer;'><td onclick='clickTag(\""+ sJson.TagList[i] +"\");'>"+ sJson.TagList[i] +"</td></tr>";

			if ( i == 0 )
			{
				var tBody = "<table border='0' cellspacing='0' cellpadding='0'>" + sBody;
				var splArea = "<table width='100%' border='0' cellspacing='0' cellpadding='0'>" + tsplArea;
			} else	{
				var tBody = tBody + sBody;
				var splArea = splArea + tsplArea;
			}

			
			if ( i > 3 )
			{
				break;
			}
		}

		if ( tBody == undefined )
		{
			var tBody = "<table border='0' cellspacing='0' cellpadding='0'>";
		}
		if ( splArea == undefined )
		{
			var splArea = "<table width='100%' border='0' cellspacing='0' cellpadding='0'>";
		}

		var tBody = tBody + "</table>";
		var splArea = splArea + "</table>";

		document.getElementById("DivTag").style.display = "";
		document.getElementById("DivAd").style.display = "none";
		document.getElementById("divtoo").innerHTML = tBody;
		document.getElementById("iconroll").style.display = "";
		document.getElementById("iconarea").style.display = "";		

		document.getElementById("splArea").innerHTML = splArea;
	}
}


document.write("<iframe style=\"display:none;\" name=\"frmBAR\"></iframe>");	


var Wid_offsetxpoint=10
var Wid_offsetypoint=5
var Wid_ie=document.all
var Wid_ns6=document.getElementById && !document.all
var Wid_enabletip=false
//if (ie||ns6)
//var tipobj=document.all? document.all["dhtmltooltip"] : document.getElementById? document.getElementById("dhtmltooltip") : ""
var Wid_tipobj=document.getElementById("widgettooltip");

//alert( tipobj );
//alert( document.getElementById("dhtmltooltip") );

function Wid_ietruebody(){
	return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body
}

function Wid_showTip(thetext, thecolor, thewidth){
	if (Wid_ns6||Wid_ie){
		if (typeof thewidth!="undefined") Wid_tipobj.style.width=thewidth+"px"
		if (typeof thecolor!="undefined" && thecolor!="") Wid_tipobj.style.backgroundColor=thecolor
//alert( tipobj );
//alert( thetext );
		Wid_tipobj.innerHTML=thetext
//alert( "a" );
		Wid_enabletip=true
		return false
	}
}

function Wid_positiontip(e){
//alert("a")
	if (Wid_enabletip){
		var curX=(Wid_ns6)?e.pageX : event.clientX+Wid_ietruebody().scrollLeft;
		var curY=(Wid_ns6)?e.pageY : event.clientY+Wid_ietruebody().scrollTop;
		var rightedge=Wid_ie&&!window.opera? Wid_ietruebody().clientWidth-event.clientX-Wid_offsetxpoint : window.innerWidth-e.clientX-Wid_offsetxpoint-20;
		var bottomedge=Wid_ie&&!window.opera? Wid_ietruebody().clientHeight-event.clientY-Wid_offsetypoint : window.innerHeight-e.clientY-Wid_offsetypoint-20;
		var leftedge=(Wid_offsetxpoint<0)? Wid_offsetxpoint*(-1) : -1000;

		if (rightedge<Wid_tipobj.offsetWidth)	{
			Wid_tipobj.style.left=Wid_ie? Wid_ietruebody().scrollLeft+event.clientX-Wid_tipobj.offsetWidth+"px" : window.pageXOffset+e.clientX-Wid_tipobj.offsetWidth+"px"
		}	else if (curX<leftedge)	{
			Wid_tipobj.style.left="5px"
		}	else	{
			Wid_tipobj.style.left=curX+Wid_offsetxpoint+"px"
		}

		if (bottomedge<Wid_tipobj.offsetHeight)	{
			Wid_tipobj.style.top=Wid_ie? Wid_ietruebody().scrollTop+event.clientY-Wid_tipobj.offsetHeight-Wid_offsetypoint+"px" : window.pageYOffset+e.clientY-Wid_tipobj.offsetHeight-Wid_offsetypoint+"px"
		}	else if (curX<leftedge)	{
			Wid_tipobj.style.left="5px"
		}	else	{
			Wid_tipobj.style.left=curX+Wid_offsetxpoint+"px"
		}

		if (bottomedge<Wid_tipobj.offsetHeight)	{
			Wid_tipobj.style.top=Wid_ie? Wid_ietruebody().scrollTop+event.clientY-Wid_tipobj.offsetHeight-Wid_offsetypoint+"px" : window.pageYOffset+e.clientY-Wid_tipobj.offsetHeight-Wid_offsetypoint+"px"
		}	else	{
			Wid_tipobj.style.top=curY+Wid_offsetypoint+"px"
			Wid_tipobj.style.visibility="visible"
		}
	}
}

function hideTip(){
	if (Wid_ns6||Wid_ie){
		Wid_enabletip=false;
		Wid_tipobj.style.visibility="hidden";
		Wid_tipobj.style.left="-1000px";
		Wid_tipobj.style.backgroundColor='';
		Wid_tipobj.style.width='';
	}
}

document.onmousemove=Wid_positiontip;

/////////////////////////////////////////////////////////////////////////////////

