
//Å« ÀÌ¹ÌÁö ¹Ì¸®º¸±â Ã¢
var dragapproved=false
function drag_dropie(){
if (dragapproved==true){
document.all.GD_ImageView.style.pixelLeft=tempx+event.clientX-iex
document.all.GD_ImageView.style.pixelTop=tempy+event.clientY-iey
return false
}
}
function initializedragie(){
iex=event.clientX
iey=event.clientY
tempx=GD_ImageView.style.pixelLeft
tempy=GD_ImageView.style.pixelTop
dragapproved=true
document.onmousemove=drag_dropie
}

if (document.all){
document.onmouseup=new Function("dragapproved=false")
}
//end

function sub_hidden(){
 GD_ImageView.style.display='none';
}

function Onshow(su)
{
	document.goods.action = '/html/Popup/GD_FrontImgShow.html?su=' + su;
	document.goods.target = 'hiddeniframe';
	document.goods.method = 'post';
	document.goods.submit();
}
//Å« ÀÌ¹ÌÁö ¹Ì¸®º¸±â Ã¢

function OnPreview(su)
{
	document.goods.action = '/html/Popup/GD_FrontSimplePage.html' + ((su>=1)? 'su=' + su:'');
	document.goods.target = 'hiddeniframe';
	document.goods.method = 'post';
	document.goods.submit();
}


// *********************************************************************//
//	2009 04 01 »õ·Ó°Ô ÀÛ¼ºµÈ ÁÙ																				//
//

function OnView2(tmp) {
	randimg.src = tmp;
}

function Onshow2(code,ItemCode,quantity,reserve,q_size,exe_tmp,su,tmp)
{
	document.ImgForm.code2.value = code;
	document.ImgForm.ItemCode2.value = ItemCode;
	document.ImgForm.quantity2.value = (tmp)? quantity:document.ImgForm.quantity2.value;
	document.ImgForm.reserve2.value = (tmp)? reserve:document.ImgForm.reserve2.value;
	document.ImgForm.q_size2.value = (tmp)? q_size:document.ImgForm.q_size2.value;
	document.ImgForm.exe_tmp2.value = (tmp)? exe_tmp:document.ImgForm.exe_tmp2.value;

	document.ImgForm.action = '/html/front/Popup/GD_FrontImgShow.html?code2='+code+'&ItemCode2='+ItemCode + ((su>=1)? '&su=' + su:'');
	document.ImgForm.target = 'hiddeniframe';
	document.ImgForm.method = 'post';
	document.ImgForm.submit();
}
//Å« ÀÌ¹ÌÁö ¹Ì¸®º¸±â Ã¢

function OnPreview2(code,ItemCode,quantity,reserve,q_size,exe_tmp,su,tmp)
{
	document.ImgForm.code2.value = code;
	document.ImgForm.ItemCode2.value = ItemCode;
	document.ImgForm.quantity2.value = (tmp)? quantity:document.ImgForm.quantity2.value;
	document.ImgForm.reserve2.value = (tmp)? reserve:document.ImgForm.reserve2.value;
	document.ImgForm.q_size2.value = (tmp)? q_size:document.ImgForm.q_size2.value;
	document.ImgForm.exe_tmp2.value = (tmp)? exe_tmp:document.ImgForm.exe_tmp2.value;

	document.ImgForm.action = '/html/front/Popup/GD_FrontSimplePage.html?code2='+code+'&ItemCode2='+ItemCode + ((su>=1)? '&su=' + su:'');
	document.ImgForm.target = 'hiddeniframe';
	document.ImgForm.method = 'post';
	document.ImgForm.submit();
}

//
// *********************************************************************//

function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}
 
function MM_preloadImages() { //v3.0
  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];}}
}
 
function MM_findObj(n, d) { //v4.01
  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;
}
 
function MM_swapImage() { //v3.0
  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];}
}


/*
³×ÀÌ¹ö Ã¼Å©¾Æ¿ô Àü¼Û
*/
function gotoNaverWish()
{
	var fm = document.goods;
	var selling = fm.selling.value;
	var quantity = fm.quantity.value;
 
	if (selling != "0") {
		alert("³×ÀÌ¹ö Ã¼Å©¾Æ¿ôÀ¸·Î ±¸¸Å ºÒ°¡ÇÑ »óÇ°ÀÔ´Ï´Ù.");
		return;
	}
 
	if (quantity <= "0") {
		alert("³×ÀÌ¹ö Ã¼Å©¾Æ¿ôÀ¸·Î ±¸¸Å ºÒ°¡ÇÑ »óÇ°ÀÔ´Ï´Ù.");
		return;
	}
 
 
	window.open("", "winNaverWish",  "width=380,height=380,no");
	
	fm.target = "winNaverWish";
	fm.action = "/Order/naverCheckout.asp?Url=naverWish.asp";
	fm.method = "POST";
	fm.submit();

}
 
function gotoNaverCart()
{
	var fm = document.goods;
	var selling = fm.selling.value;
	var quantity = fm.quantity.value;
 
	if (selling != "0") {
		alert("³×ÀÌ¹ö Ã¼Å©¾Æ¿ôÀ¸·Î ±¸¸Å ºÒ°¡ÇÑ »óÇ°ÀÔ´Ï´Ù.");
		return;
	}
 
	if (quantity <= "0") {
		alert("³×ÀÌ¹ö Ã¼Å©¾Æ¿ôÀ¸·Î ±¸¸Å ºÒ°¡ÇÑ »óÇ°ÀÔ´Ï´Ù.");
		return;
	}

	if(gdFrontCheck(fm) == true) return;
 
 
	fm.target = "_top";
	fm.action = HttpDomain + "/Order/GD_Basket_Pass.html?nc_rurl=/Order/naverCheckout.asp?Url=naverOrder.asp";
	fm.method = "POST";
	fm.submit();

}
/*
³×ÀÌ¹ö Ã¼Å©¾Æ¿ô Àü¼Û
*/

var tx_code = "";
var tx_sellid = "";
var tx_reserve = "";
var tx_rterm = "";

