function goURL(url)
{
 	window.document.location = url;
	return;
}
function snapshotsub()
{
	var CodeValue='';
	var PageValue='';
	var err=1;

	CodeValue = document.snapshotForm.code.value;
	PageValue = document.snapshotForm.page.value;

	/* ÇÑ±Û Ã¼Å© */
	if( CodeValue.length != 5) err=0;
	if (isNaN(CodeValue)) err = 0;
	
	if( err )
	{
		url = 'http://stock.hankyung.com/cgibin/snapshot?code=' + CodeValue + '&page=' + PageValue;

              	document.location.href = url;
	}else{
		url = 'http://stock.hankyung.com/cgibin/Mcodesearch?code=' + CodeValue;              	
              	jwopen(url, 300, 350,'yes','yes');
	}	
	return;
}

function searchsub()
{
	var SrchValue='';

	SrchValue = document.searchForm.kisa.value;

	var SrL = SrchValue.length;
	if (SrchValue != '' && SrL >= 2)
	{ // ±â»ç°Ë»ö Ã³¸®ºÎºÐ

             	if (e4) kisa = 'http://hksearch.hankyung.com/cgi-bin/kedsearch.cgi?cat=%62%72%64%69%72&work=%53%65%61%72%63%68%5F%43%61%73%65&tw=%34%35%30&rf=%41%4C%4C&kinds=%31&k_class=%41%4C%4C&OM=%64%61%74%65%5F%64%65%73%63%64%61&pp=%31%30&st='+SrchValue;
              	else kisa = 'http://hksearch.hankyung.com/cgi-bin/kedsearch.cgi?cat=%62%72%64%69%72&work=%53%65%61%72%63%68%5F%43%61%73%65&tw=%34%35%30&rf=%41%4C%4C&kinds=%31&k_class=%41%4C%4C&OM=%64%61%74%65%5F%64%65%73%63%64%61&pp=%31%30&st='+escape(SrchValue);
              	
              	document.location.href = kisa;
	}
	return;
}

function searchsub1()
{
	var SrchValue='';
	var srchGubun='';

	SrchValue = document.searchForm1.kisa.value;
	SrchGubun = document.searchForm1.gubun.value;

	var SrL = SrchValue.length;
	if (SrchValue != '' && SrL >= 2)
	{ // ±â»ç°Ë»ö Ã³¸®ºÎºÐ
	      if( SrchGubun == '1')
	      {
              	if (e4) kisa = 'http://hksearch.hankyung.com/cgi-bin/kedsearch.cgi?cat=%62%72%64%69%72&work=%53%65%61%72%63%68%5F%43%61%73%65&tw=%34%35%30&rf=%41%4C%4C&kinds=%31&k_class=%41%4C%4C&OM=%64%61%74%65%5F%64%65%73%63%64%61&pp=%31%30&st='+SrchValue;
              	else kisa = 'http://hksearch.hankyung.com/cgi-bin/kedsearch.cgi?cat=%62%72%64%69%72&work=%53%65%61%72%63%68%5F%43%61%73%65&tw=%34%35%30&rf=%41%4C%4C&kinds=%31&k_class=%41%4C%4C&OM=%64%61%74%65%5F%64%65%73%63%64%61&pp=%31%30&st='+escape(SrchValue);
              	
              	document.location.href = kisa;
              	
              }else{
              	if (e4) kisa = 'http://hksearch.hankyung.com/cgi-bin/termdic_search.cgi?work=%53%65%61%72%63%68%5F%43%61%73%65&tw=%34%35%30&tl=../dic/dic_list.html&tc=../dic/dic_cont.html&rf=%74%65%72%6D&st='+SrchValue;
              	else kisa = 'http://hksearch.hankyung.com/cgi-bin/termdic_search.cgi?work=%53%65%61%72%63%68%5F%43%61%73%65&tw=%34%35%30&tl=../dic/dic_list.html&tc=../dic/dic_cont.html&rf=%74%65%72%6D&st='+escape(SrchValue);
              	
              	jwopen(kisa, 500, 350,'yes','yes');
              }	
	}
	return;
}

function   stocksub()
{
	var StockValue = '';
	var SearchCgi;
    	StockValue= new String(this.document.stockForm.jongmok.value);
    	if(StockValue != '') { 
	    if(StockValue.substring(0,1) >= '0' && StockValue.substring(0,1) <= '9')
	    { 
		if(StockValue.length < 2) {
			alert("µÎÀÚ¸®ÀÌ»ó ÀÔ·ÂÇØ¾ß ÇÕ´Ï´Ù.");
			return;
		}
		SearchCgi = "http://stock.hankyung.com/cgibin/stocksearch"+"?gu=1&code="+StockValue;
	    }
    	    else 
	    {
		SearchCgi = "http://stock.hankyung.com/cgibin/stocksearch"+"?gu=2&code="+StockValue;
	    }
		document.location = SearchCgi;
		return;
	}
	else 
	 return ;
}

function jwopen(htm, ht, wd,sc,rs)
{
    if ((win == 0) || win.closed) {
    	win=window.open(htm,'searchWin','height='+ht+',width='+wd+',scrollbars='+sc+',resizable='+rs+',screenX=500,screenY=500');
    }
    var w = win;
    win.focus();
}

