function open_window( filename, option, name )
{
	if( !name )
	{
		name = 'new'
	}


        win = window.open( filename, name, option );

        return win
}

function window_open( page, name, top, left, width, height )
{
	option = "'toolbar=no," +
		"location=no," +
		"directories=no," +
		"status=no," +
		"menubar=no," +
		"scrollbars=yes," +
		"resizable=yes," +
		"width=" + width + "," +
		"height=" + height + "," +
		"top=" + top + "," +
		"left=" + left + "'"

        window.open( page, name, option );
}

function open_poll_pop( mode, no )
{
	page = '/front/php/poll_r.php?mode=' + mode + '&no=' + no;
	window_open( page, 'poll', 100, 300, 466, 382 );
}

/*Left menu ¹ÝÅõ¸í ·¹ÀÌ¾î ±¸Çö*/
function Layer_overload(LayerName,Status) 
{
    if (navigator.appName == "Netscape")
    {
		LayerN = document.getElementById(LayerName).style;
		if (Status == 'show') LayerN.visibility = 'visible';
		if (Status == 'hide') LayerN.visibility = 'hidden';
    }	
    else
    {
		LayerN = document.all[LayerName].style;
		if (Status == 'show') LayerN.visibility = 'visible';
		if (Status == 'hide') LayerN.visibility = 'hidden';
    }
}

/*Left menu±¸Çö*/
var old='';

function menu(name)
{
	submenu=eval("submenu_"+name+".style");
	if(old!=submenu)
	{
		if(old!='')
		{
			old.display='none';
		}
		submenu.display='block';
		old=submenu;
	}
	else
	{
		submenu.display='none';
		old='';
	}
}


function Layer_rollover(img_name,img_url)
{
	var menu;	
	//tmp = new String( "document."+img_name );
	menu=eval("document."+img_name);		
	menu.src = img_url;
	return;
}

function image_zoom( product_no, main_cate_no, display_group )
{
	//href = '/front/php/image_zoom.php?img='+image+'&product_no='+document.frm.product_no.value;
	href = '/front/php/image_zoom.php?product_no='+product_no+'&main_cate_no='+main_cate_no+'&display_group='+display_group;
	option = 'toolbar=no,scrollbars=no,resizable=yes,width=800,height=640,left=0,top=0';
	win_name = 'image'

	window.open( href, win_name, option );
}
function embedGet(arrayKey, arrayValue, Value) { 
    count = arrayKey.length; 
    for(i=0;i<count;i++) { 
        if(arrayKey[i]==Value) { 
            return arrayValue[i]; 
            break; 
        } 
    } 
} 
// ie ativeX Ãâ·Â º¯°æ ÇÔ¼ö 
function embedTo() { 
    var emtype; 
    var key = new Array(); 
    var value = new Array(); 
  // error_check=0; 
    for(i=0;i<embedTo.arguments.length;i++) { 
        data = embedTo.arguments[i].split('='); 
        key[i] = data[0]; 
        value[i] = data[1]; 
    } 

    contents = ''; 
    srcdata = embedGet(key,value,'src').toLowerCase(); 

    classid = embedGet(key,value,'classid'); 
    codebase = embedGet(key,value,'codebase'); 
    
    if(/\.(swf)$/.test(srcdata)) { //flash 
        classid = 'clsid:D27CDB6E-AE6D-11cf-96B8-444553540000'; 
        codebase = 'http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.c-ab#version=6,0,29,0'; 
        emtype="flash"; 
    } else if(/\.(wmv|wma|asf|avi|wav|asx|mpeg|mp3|midi|aiff|au|wpl|wm|wmx|wmd|wmz)$/.test(srcdata)){//media 
        classid = 'CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95'; 
        codebase = 'http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=5,1,52,701'; 
        emtype="media"; 
    } 
    if(classid && codebase) { 
        contents += '<object activated=1'; 
        if(classid) { 
            contents += ' classid="' + classid + '"'; 
        } 
        if(codebase) { 
            contents += ' codebase="' + codebase + '"'; 
        } 
        count = key.length; 
        for(i=0;i<count;i++) { 
            if(value[i]!='') { 
                if(key[i]!='src') { 
                    contents += ' ' + key[i] + '="' + value[i] + '"'; 
                } 
            } 
        } 
        contents += '>'; 
        for(i=0;i<count;i++) { 
            if(value[i]!='') { 
                if(emtype=='flash' && key[i]=='src') { 
                    contents += '<param name="movie" value="' + value[i] + '" />'; 
                } else  if(emtype=='media' && key[i]=='src') { 
                    contents += '<param name="filename" value="' + value[i] + '" />'; 
                } else { 
                    contents += '<param name="' + key[i] + '" value="' + value[i] + '" />'; 
                } 
            } 
        } 
    } 
    contents += '<embed'; 
    if( !(classid && codebase) ) { 
         contents += ' activated=1 '; 
    } 
    
    for(i=0;i<count;i++) { 
        if(value[i]!='') { 
            contents += ' ' + key[i] + '="' + value[i] + '"'; 
        } 
    } 
    contents += '>'; 
    contents += '</embed>'; 
    if(classid && codebase) { 
        contents += '</object>'; 
    } 
    document.write(contents); 
    //return contents; 
} 


//»ç¿ë¿¹
//<script language=JavaScript>
//embedTo("src=/image/flash/menu.swf","width=620","height=49");
//</x-script>



function bookmark(){
window.external.AddFavorite('http://www.widegem.com', '¿ÍÀÌµåÁª-ÆÐ¼ÇÁê¾ó¸® Àü¹® ¼îÇÎ¸ô')
}


function view(x,y,z){
  newin=window.open('',y,z);
  newin.document.write("<head><title> View Image</title></head><body background='"+x+"' onclick='self.close()' style='cursor:hand'>");
}
