");
}
function imgpreview2(id,uid)
{
var KimsonPopupCheck = getPopUpFlag(window.open('','iwin','left=0,top=0,width=100,height=100,scrollbars=yes,status=yes'));
KimsonPopupCheck.document.write("
미리보기
\
");
}
function showInvWin(url)
{
getPopUpFlag(window.open(url , 'articlewin' , 'left=0,top=0,width=800,height=600,scrollbars=yes,status=yes'));
}
function zoom(uid)
{
window.open('../../_system/module/shop/zoom.php?uid=' + uid,'','left=0,top=0,width=480,height=555,scrollbars=no,status=yes');
}
function getTpriceLoyaltyJs(tprice,val)
{
var tmpval = val ? val : 1;
return parseInt(Math.floor(parseInt(tprice)/tmpval ) * tmpval);
}
function getLoginNeed()
{
if(confirm('로그인하셔야 이용하실 수 있습니다. \n\n지금 로그인하시겠습니까?'))
{
location.href = "./login.php?referer=" + escape(location.href);
}
}
function getDownInfo(uid)
{
window.open('../../_system/module/upload/info.php?uid=' + uid,'','left=0,top=0,width=480,height=555,scrollbars=yes,status=yes');
}
function return_phone(returnEl, useFocus)
{
var returnVal = ""; //리턴되는 값
var inputVal; //입력된값을 저장하는 곳
inputVal = returnEl.value;
this.form = returnEl.form;
inputVal = inputVal.replace(/\-/g,"");
inputVal = inputVal.replace(" ","");
var valuelen = inputVal.length;
if(valuelen>11) valuelen = 11;
var firstnum = inputVal.substr(0,1);
var num = "";
if (firstnum != 0 && firstnum != 1 && firstnum != ""){
this.form.elements[returnEl.name].value = '';
this.form.elements[returnEl.name].focus();
}else if(firstnum == 1){
for (i = 0; i < 8; i++) {
num = inputVal.substr(i,1);
pattern = /([0-9])/;
if(pattern.test(num)) returnVal += num;
}
}else{
for (i = 0; i < valuelen; i++) {
num = inputVal.substr(i,1);
pattern = /([0-9])/;
if(pattern.test(num)) returnVal += num;
}
}
if(returnVal.length >= 9){
if(returnVal.substring(0,2)=='02') var pattern = /^([0]{1}[0-9]{1})?([1-9]{1}[0-9]{2,3})?([0-9]{4})$/;
else if(returnVal.substring(0,4)=='0505') var pattern = /^([0]{1}[0-9]{3})?([1-9]{1}[0-9]{2})?([0-9]{4})$/;
else var pattern = /^([0]{1}[0-9]{2})?([1-9]{1}[0-9]{2,3})?([0-9]{4})$/;
if (pattern.exec(returnVal)) {
if(RegExp.$1=="02" || RegExp.$1 == "010" || RegExp.$1 == "011" || RegExp.$1 == "016" || RegExp.$1 == "017" || RegExp.$1 == "018" || RegExp.$1 == "019" || RegExp.$1=="031" || RegExp.$1=="032" || RegExp.$1=="033" || RegExp.$1=="041" || RegExp.$1=="042" || RegExp.$1=="043" || RegExp.$1=="051" || RegExp.$1=="052" || RegExp.$1=="053" || RegExp.$1=="054" || RegExp.$1=="055" || RegExp.$1=="061" || RegExp.$1=="062" || RegExp.$1=="063" || RegExp.$1=="064") {
if(!returnEl.getAttribute("span")) returnVal = RegExp.$1 + "-" + RegExp.$2 + "-" + RegExp.$3;
}
}
}else if(returnVal.length == 8 && firstnum==1){
var pattern = /^([1]{1}[0-9]{3})?([0-9]{4})$/;
if (pattern.exec(returnVal)) {
returnVal = RegExp.$1 + "-" + RegExp.$2;
}
}
this.form.elements[returnEl.name].value = returnVal;
if (useFocus==1){ //포커스를 잃어버릴때 다시 포커스 잡히지 않도록
this.form.elements[returnEl.name].focus();
}
}
//이미지 출력시의 썸네일 출력
function show_img_crop(img_url,img_width,img_height,prmvw,upfile,id,ruid,prmdn,uuid)
{
img = new Image();
img.src = img_url;
//top_pos = (img.height * img_width / img.width - img_height) / 2 * -1;
top_pos = 0;
document.write("
");
}
function DrawObjects(id)
{
document.write ( "
" );
rootObject.print ();
var current = rootObject.next;
for (var i = 0; current != rootObject; i++) {
current.print();
current = current.next;
}
document.write("