ÿØÿà JFIF ` ` ÿþ
Server : Apache System : Linux ruga7-004.fmcity.com 3.10.0-1160.119.1.el7.x86_64 #1 SMP Tue Jun 4 14:43:51 UTC 2024 x86_64 User : tkt_travelbus ( 1137) PHP Version : 7.0.0p1 Disable Function : mysql_pconnect Directory : /tkt_travelbus/www/toadmin/hotel/ |
Upload File : |
<? include "../include/top.html"; include "_common.php"; $data = hotel_list(" and hseq='{$hseq}' "); $rows = hotel_list_replace($data[0]); //지역코드 if ($rows['areaa_cd']) $data_areab = ($cf['tab']['L']=="Y") ? to_area_b($rows['areaa_cd'],""," and DelFlagH='N' "):to_area_b($rows['areaa_cd'],""," and DelFlag='N' "); // 국가 if ($rows['areab_cd']) $data_areac = ($cf['tab']['L']=="Y") ? to_area_c("",$rows['areab_cd'],"",""," and DelFlagH='N' "):to_area_c("",$rows['areab_cd'],"","N"); // 도시 //지하철 코드 if($rows['subway_city_cd']) $data_subway2 = base_codec("SUB",$rows['subway_city_cd']); //$code_thema = base_codec("HTL","THEM");//목적구분 $code_equipment = base_codec("HTL","EQUP");//객실설비비품 $b_uid = $rows[b_uid]; $m_uid = $rows[m_uid]; //1차 카테고리 //$bc_arr = TO_get_bc("","N"," and tab = 'L' "); if($b_uid_s) $bc_arr = TO_get_bc($b_uid_s,"N"," and tab='L' "); else $bc_arr = TO_get_bc("","N"," and tab='L' "); //언어 $lang = $bc_arr[0][b_lang]; if($lang=="ko") { $lang_txt = "한국"; $good_url = "https://www.tourboss.co.kr/"; } else if($lang=="en") { $lang_txt = "영어"; $good_url = "https://en.tktravelkorea.com/"; } else if($lang=="cn") { $lang_txt = "간체"; $good_url = "http://cn.tktravelkorea.com/"; } else if($lang=="hk") { $lang_txt = "번체"; $good_url = "https://www.tktravelkorea.com/"; } $data_areaa = to_area_a("","N",$lang); // 대륙 // 특징아이콘 $special_arr = base_codec("TGO","TSPE","","N"); // 관리자목록 $admin_arr = member_fetch(" and mb_level <= 10 "); // 룸타입 $data_hotel_div = base_codec("HTL","HLDC","","N"); //관련상품 //모든 1차카테고리 $data_bc1 = TO_get_bc($b_uid_s,"N"," and tab='L' "); $lang = $data_bc1[0]['b_lang']; $data_bc = TO_get_bc("","N"," and b_lang='{$lang}'"); //관련호텔 출력 $regood_arr = array(); $regood = db_query("select * from TB_GOOD_RELATED where g_uid='$hseq' order by ordernum"); while ($rowgood = db_fetch_array($regood)) { $regood_arr[] = $rowgood; } $CommonTour = new CommonTour(); //공급처 $prod_arr = member_fetch(" and mb_level ='13' and del_flag='N' "); $getSeoSecondCategoryUrl = getSeoHotelSecondCategoryUrl(); ?> <div class="contents_wrap"> <div class="contents_wrap_in"> <div class="title"><?=$rows['hotel_nm']?><span class="arrow">></span><strong>기본 정보</strong></div> <div class="contents_detail"> <div id="Content_box"> <? include "_menu.html"; ?> <!-- 폼 --> <form name="frm_ins" id="frm_ins" method="post" enctype="multipart/form-data"> <input type="hidden" name="SqlType" value="hotel_edit_base" /> <input type="hidden" name="hseq" value="<?=$hseq?>" /> <input type="hidden" name="seller_id" id="seller_id" value="<?=$rows['seller_id']?>" /> <p style="background-color:#EEE;"> </p> <table width="100%" border="0" cellspacing="0" cellpadding="0" class="t_register input300" summary="호텔의 기본정보를 수정합니다."> <caption>호텔 기본정보 수정</caption> <colgroup> <col width="170px;" /> <col /> </colgroup> <tbody> <tr> <th scope="row"><label for="hotel_nm">상품URL</label></th> <td style="color:#00F;"> <?=$good_url?>hotel/hotel_view.html?b_uid_s=<?=$b_uid?>&hseq=<?=$hseq?>&pass=ok <img src="/image/icons/application_view_gallery.png" alt="미리보기" onclick="window.open('<?=$good_url?>hotel/hotel_view.html?b_uid_s=<?=$b_uid?>&hseq=<?=$hseq?>&pass=ok'); return false;" style="cursor:pointer;"/> <a href="#" onclick="copy_url('<?=$good_url?>hotel/hotel_view.html?b_uid_s=<?=$b_uid?>&hseq=<?=$hseq?>&pass=ok'); return false;"><input type="image" src="/image/icons/page_paste.png" align="top" alt="링크복사" /></a> <br> <br> <input type="hidden" id="nowDomainUrl" value="<?=$good_url?>" /> <input type="hidden" id="newUrlAddress" value="<?=$good_url?><?=$rows['seo_first_category_url']?>/<?=$rows['seo_second_category_url']?>/<?=$rows['seo_good_url']?>/" /> <?php ?> <b id="seoUrlAddress" style="font-weight:normal;color:#00f">[변경] URL : <?=$good_url?><?=$rows['seo_first_category_url']?>/<?=$rows['seo_second_category_url']?>/<?=$rows['seo_good_url']?>/</b> <a href="<?=$good_url?><?=$rows['seo_first_category_url']?>/<?=$rows['seo_second_category_url']?>/<?=$rows['seo_good_url']?>/" target="_blank" id="newUrlLink" > <!-- <i class="xi-external-link" style="cursor: pointer; color: #000; font-size: 13px; position: relative; top: 1px;"></i>--> <img src="/image/icons/application_view_gallery.png"/> </a> <input id="newUrlCopyBtn" type="image" src="/image/icons/page_paste.png" align="top" alt="링크복사" /> <!-- <i class="xi-scissors" style="cursor: pointer; color: #000; font-size: 13px; position: relative; top: 1px;"></i>--> </td> </tr> <?php if($cf['tab']['L']=="Y") {?> <tr> <th scope="row"><label for="hotel_nm">카테고리</label></th> <td> <select name="b_uid" id="b_uid" size="10" onchange="$('#ajax_sc').html('');ajax_obj_loader('../good/good_edit_category_ajax.html?mode=mc&b_uid='+this.value,'ajax_mc');" style="width:140px; background:none;"> <option value="" style="background:#000000;color:#ffffff;">==1차카테고리==</option> <?php for($i=0 ; $i<count($bc_arr) ; $i++) { $arr = $bc_arr[$i]; ?> <option value="<?=$arr['b_uid']?>" <?=($arr['b_uid']==$rows['b_uid'])?"selected":""?>>[<?=$arr['b_uid']?>] <?=$arr['b_name']?></option> <? } ?> </select> <span id="ajax_mc"></span><!-- 2차 카테고리 --> <span id="ajax_sc"></span><!-- 3차 카테고리 --> </td> </tr> <?php }?> <tr> <th scope="row" style="border-bottom:1px solid red"><label for="hotel_nm">호텔명</label></th> <td style="border-bottom:1px solid red"> <strong class="pr10"><?=$lang_txt?></strong><input name="hotel_nm" id="hotel_nm" type="text" class="input_text" hname="숙소명" style="width:580px" required value="<?=$rows['hotel_nm']?>"/><br> <strong class="pr10">영문</strong><input name="hotel_nm_eng" id="hotel_nm_eng" type="text" class="input_text" style="width:580px" value="<?=$rows['hotel_nm_eng']?>"/> </td> </tr> <tr> <th style="border-left:1px solid red;border-bottom:1px solid red;border-top:1px solid #e4e4e4" width="150" scope="row"> 컨텐츠 정보 URL 설정 <br> <p style="color:red;font-size: 11px;">(영문 소문자,숫자,-만 사용가능)</p> </th> <td style="border-right:1px solid red;border-bottom:1px solid red"> <input type="hidden" name="seoLang" id="seoLang" value="<?=$lang?>" /> First URL : <?php if(!$rows['seo_first_category_url']){ ?> <select id="seo_first_category_url" name="seo_first_category_url"> <option value="">선택하세요.</option> <?php foreach($seoHotelFirstCategoryUrl as $item){ ?> <option value="<?=$item?>" <?=(($rows['seo_first_category_url'] == $item) ? 'selected' : '')?>><?=$item?></option> <?php } ?> </select> <?php }else{ ?> <input type="text" id="seo_first_category_url" class="input_text" name="seo_first_category_url" value="<?=$rows['seo_first_category_url']?>" readonly /> <?php } ?> / Second URL : <?php // p($getSeoCategoryUrl); if(!$rows['seo_second_category_url']){ ?> <select id="seo_second_category_url" name="seo_second_category_url"> <option value="">선택하세요.</option> <?php foreach($getSeoSecondCategoryUrl as $item){ ?> <option value="<?=$item['seo_second_category_url']?>" <?=(($rows['seo_second_category_url'] == $item['seo_second_category_url']) ? 'selected' : '')?>><?=$item['seo_second_category_url']?></option> <?php } ?> </select> <?php }else{ ?> <input type="text" id="seo_second_category_url" class="input_text" name="seo_second_category_url" value="<?=$rows['seo_second_category_url']?>" readonly /> <?php } ?> <span id="seoCategoryUrlAddBtn" style="display:<?=(($row['seo_second_category_url'] && $row['seo_good_url']) ? 'none' : '')?>">추가</span> <input type="text" id="seoCategoryUrlFieldAdd" class="input_text"/> <span id="seoCategoryUrlRegBtn">등록</span> / Good URL : <input type="text" style="width:500px" class="input_text" id="seo_good_url" name="seo_good_url" value="<?=$rows['seo_good_url']?>" <?=(($rows['seo_good_url']) ? 'readonly' : '')?> required /> <span id="seoDuplicateCheckBtn" style="display:<?=(($row['seo_second_category_url'] && $row['seo_good_url']) ? 'none' : '')?>" isCheck="<?=(($rows['seo_first_category_url'] && $rows['seo_second_category_url'] && $rows['seo_good_url']) ? 'Y' : '')?>">중복체크</span> <?php // if(($row['seo_first_category_url'] && $row['seo_second_category_url'] && $row['seo_good_url'])){ ?> <span id="seoUrlInitBtn" hseq="<?=$hseq?>">초기화</span> <?php // } ?> </td> </tr> <style> #seo_first_category_url, #seo_second_category_url{width:136px !important} #seoUrlInitBtn, #seoCategoryUrlAddBtn, #seoCategoryUrlRegBtn, #seoDuplicateCheckBtn{border: 1px solid #ccc;background: #fff;padding: 5px 9px;border-radius: 5px;top: 2px;position: relative;cursor:pointer} #seoCategoryUrlFieldAdd,#seoCategoryUrlRegBtn{display:none} #seoCategoryUrlRegBtn{background:#1a1a1a;color:#fff;border:1px solid #1a1a1a;margin-right:5px} #b2bPdfFileArea label{color:#1f1f1f} #seoUrlInitBtn{float:right} #seoCategoryUrlFieldAdd{width:134px} </style> <tr> <th scope="row">호텔등급</th> <td> <select name="level_cd" id="level_cd" class="lo_left"> <option value="">==등급==</option> <? for($i=0 ; $i < count($data_hotel) ; $i++){ $row = $data_hotel[$i]; ?> <option value="<?=$row['code']?>" <?=($rows['level_cd']==$row['code'])?"selected":""?>><?=$row['cd_nm']?></option> <? } ?> </select> <span class="img_p" id="hotel_level_img"></span> </td> </tr> <?if($rows['exchange_fg']=="Y"){?> <tr> <th scope="row">현재적용환율</th> <td> 1<?=$rows['ext_eng']?>(<?=$rows['ext_nm']?>) → <?=$rows['ext_to_krw']?>KRW(원) </td> </tr> <?}?> <tr> <th scope="row">호텔구분</th> <td> <select name="hotel_div_cd" id="hotel_div_cd" class="lo_left"> <option value=""></option> <? for($i=0 ; $i < count($data_hotel_div) ; $i++){ $v = $data_hotel_div[$i]; ?> <option value="<?=$v['code']?>" <?=($rows['hotel_div_cd']==$v['code'])?"selected":""?>><?=$v['cd_nm']?></option> <?}?> </select> </td> </tr> <tr> <th scope="row">지역</th> <td> <select name="areaa_cd" id="areaa_cd" onchange="ajax_loader('../hotel/ajax_area_selbox.html?SqlType=areab&areaa_cd='+this.value,'ajax_areab_cd');" class="lo_left mr5"> <option value="">==대륙==</option> <? for($i=0 ; $i < count($data_areaa) ; $i++){ $arr = $data_areaa[$i]; ?> <option value="<?=$arr['Aidx']?>" <?=($arr['Aidx']==$rows['areaa_cd'])?"selected":""?>><?=$arr['ContinentName']?></option> <?}?> </select> <span id="ajax_areab_cd"> <select name="areab_cd" id="areab_cd" onchange="ajax_loader('../hotel/ajax_area_selbox.html?SqlType=areac&areab_cd='+this.value,'ajax_areac_cd');" class="lo_left mr5"> <option value="">==국가==</option> <? for($i=0 ; $i < count($data_areab) ; $i++){ $arr = $data_areab[$i]; ?> <option value="<?=$arr['Bidx']?>" <?=($arr['Bidx']==$rows['areab_cd'])?"selected":""?>><?=$arr['NationName']?></option> <?}?> </select> </span> <span id="ajax_areac_cd"> <select name="areac_cd" id="areac_cd" class="lo_left mr5"> <option value="">==도시==</option> <? for($i=0 ; $i < count($data_areac) ; $i++){ $arr = $data_areac[$i]; ?> <option value="<?=$arr['Cidx']?>" <?=($arr['Cidx']==$rows['areac_cd'])?"selected":""?>><?=$arr['CityName']?></option> <?}?> </select> </span> </td> </tr> <tr> <th scope="row"><label for="tel">전화번호</label></th> <td><input name="tel" id="tel" type="text" value="<?=$rows['tel']?>" style="width:365px;" class="input_text input610" /></td> </tr> <tr> <th scope="row"><label for="zipcode">주소</label></th> <td> <?if(!$cf[no_post]){?> <input name="zipcode" id="zipcode" type="text" value="<?=$rows['zipcode']?>" class="input_text" style="width:114px;" readonly /> <a href="#" class="Table_btn gray" onclick="to_dialog.iframe('../include/zipfind.html?z1=zipcode&z2=address','우편번호검색','500','400',true,false);">우편번호검색</a><br/> <?}?> <label for="address" class="v_none2">주소입력</label> <input name="address" id="address" type="text" value="<?=$rows['address']?>" size="32" class="input_text mt5" /> <label for="address_d" class="v_none2">상세주소입력</label> <input name="address_d" id="address_d" type="text" value="<?=$rows['address_d']?>" size="58" class="input_text mt5" /> </td> </tr> <tr> <th scope="row">총객실수</th> <td><input name="room_count" id="room_count" type="text" value="<?=$rows['room_count']?>" class="input_text" /></th> </tr> <tr> <th scope="row"><label for="url">홈페이지</label></th> <td><input name="url" id="url" type="text" style="width:365px;" value="<?=$rows['url']?>" class="input_text input610"/></td> </tr> <tr> <th scope="row">룸타입</th> <td> <input type="text" name="hotel_div" id="hotel_div" style="width:365px;" value="<?=$rows['hotel_div']?>" class="input_text input610"/> </td> </tr> <tr> <th scope="row"><label for="url">주변관광지</label></th> <td><input name="playland" id="playland" type="text" style="width:365px;" value="<?=$rows['playland']?>" class="input_text input610"/></td> </tr> <tr> <th scope="row">위치설명</th> <td><textarea name="position_intro" id="position_intro" style="width:750px; height:100px;" class="" ><?=$rows['position_intro']?></textarea></td> </tr> <!--<tr> <th scope="row"><label for="fax">팩스번호</label></th> <td><input name="fax" id="fax" type="text" style="width:365px;" value="<?=$rows['fax']?>" class="input_text input610"/></td> </tr>--> <tr> <th scope="row"><label for="img1">대표이미지</label></th> <td> <div class="lo_left"> <?if($rows['img1']){?><img src="<?=$rows['img1_path']?>" alt="지역이미지" width="150" height="100" style="cursor:pointer;" onClick="to_dialog.image('<?=$rows['img1_path']?>','<?=$rows['place_nm']?>')" /><?}?></div><div class="lo_left ml20 mt35"><input name="img1" id="img1" type="file" class="file_bd" /><span class="ml10">※ 넓이:높이 3:2 비율 ex) 720px x 480px</span></div> </td> </tr> <tr> <th scope="row">호텔간략소개<br>(COMMENT)</th> <td> <textarea name="hotel_brief" id="hotel_brief" class="" style="width:95%; height:100px;" ><?=$rows['hotel_brief']?></textarea><br> 작성자(MD) : <input name="hotel_brief_md" type="text" size="10" class="input_text input300" value="<?=$rows['hotel_brief_md']?>" /> </td> </tr> <tr> <th scope="row"><label for="url">00명의 선택</label></th> <td><input name="g_select_num" id="g_select_num" type="text" size="45" class="input_text input610" value="<?=$rows['g_select_num']?>" /></td> </tr> <tr> <th scope="row">공급처</th> <td> <select name="producer_id" id="producer_id" > <option value="">==선택==</option> <? for($i=0 ; $i < count($prod_arr) ; $i++){ $arr = $prod_arr[$i]; ?> <option value="<?=$arr['mb_id']?>" <?=($arr['mb_id']==$rows['producer_id'])?"selected":""?>><?=$arr['bz_corp_nm']?></option> <?}?> </select> </td> </tr> <tr> <th scope="row">관련상품설정</th> <td> <table border="0"> <tr> <td> <input type="hidden" name="idx1" value="<?=$regood_arr[0]['idx']?>"> <input type="text" class="input_text" name="related_ordernum_arr1" value="<?=$regood_arr[0]['ordernum']?$regood_arr[0]['ordernum']:'1'?>" style="width:40px"> <select name="b_uid1" id="b_uid1" onchange="$('#ajax_sc1').html('');ajax_obj_loader('../good/good_edit_category_ajax2.html?mode=mc&b_uid1='+this.value,'ajax_mc1');" style="width:140px;"> <option value="" style="background:#000000;color:#ffffff;">==1차카테고리==</option> <? for($i=0 ; $i<count($data_bc) ; $i++){ $arr = $data_bc[$i]; ?> <option value="<?=$arr['b_uid']?>" <?=($arr['b_uid']==$regood_arr[0]['b_uid'])?"selected":""?> ><?=$arr['b_name']?></option> <? } ?> </select> <span id="ajax_mc1"> <? $mc_arr = TO_get_mc($regood_arr[0]['b_uid'],"","N"); ?> <select name="m_uid1" id="m_uid1" onchange="ajax_obj_loader('../good/good_edit_category_ajax2.html?mode=sc&b_uid1=<?=$regood_arr[0]['b_uid']?>&m_uid1='+this.value,'ajax_sc1');"> <option value="" style="background:#000000;color:#ffffff;">==2차카테고리==</option> <? for($i=0 ;$i<count($mc_arr) ;$i++){ $arr = $mc_arr[$i]; ?> <option value="<?=$arr['m_uid']?>" <?=($regood_arr[0]['m_uid']==$arr['m_uid'])?"selected":""?>><?=$arr['m_name']?></option> <?}?> </select> </span><!-- 2차 카테고리 --> <span id="ajax_sc1"> <? $sc_arr = TO_get_sc($regood_arr[0]['b_uid'],$regood_arr[0]['m_uid'],"","N"); ?> <select name="s_uid1" id="s_uid1" onchange="ajax_obj_loader('../good/good_edit_category_ajax2.html?mode=good&b_uid1=<?=$regood_arr[0]['b_uid']?>&m_uid1=<?=$m_uid1?>&s_uid1='+this.value,'ajax_good1');"> <option value="" style="background:#000000;color:#ffffff;">==3차카테고리==</option> <? for($i=0 ;$i<count($sc_arr) ;$i++){ $arr = $sc_arr[$i]; ?> <option value="<?=$arr['s_uid']?>" <?=($regood_arr[0]['s_uid']==$arr['s_uid'])?"selected":""?>><?=$arr['s_name']?></option> <?}?> </select> </span><!-- 3차 카테고리 --> <span id="ajax_good1"> <? $data_good1 = $CommonTour->listGoodHotel(array("b_uid"=>$regood_arr[0]['b_uid'],"m_uid"=>$regood_arr[0]['m_uid'],"s_uid"=>$regood_arr[0]['s_uid'])); ?> <select name="g_uid1" id="g_uid1" style="width:500px"> <option value="">=상품/호텔=</option> <? for($i=0 ;$i<count($data_good1) ;$i++){ $arr = $data_good1[$i]; ?> <option value="<?=$arr['hseq']?>" <?=($regood_arr[0]['r_uid']==$arr['g_uid'])?"selected":""?>><?=$arr['g_title']?></option> <?}?> </select> <span onclick="GoodRelated('del');" style="cursor:pointer;">-</span> </span><!-- 상품 --> </td> </tr> <tr> <td> <input type="hidden" name="idx2" value="<?=$regood_arr[1]['idx']?>"> <input type="text" class="input_text" name="related_ordernum_arr2" value="<?=$regood_arr[1]['ordernum']?$regood_arr[1]['ordernum']:'2'?>" style="width:40px"> <select name="b_uid2" id="b_uid2" onchange="$('#ajax_sc2').html('');ajax_obj_loader('../good/good_edit_category_ajax2.html?mode=mc2&b_uid2='+this.value,'ajax_mc2');" style="width:140px;"> <option value="" style="background:#000000;color:#ffffff;">==1차카테고리==</option> <? for($i=0 ; $i<count($data_bc) ; $i++){ $arr = $data_bc[$i]; ?> <option value="<?=$arr['b_uid']?>" <?=($arr['b_uid']==$regood_arr[1]['b_uid'])?"selected":""?>><?=$arr['b_name']?></option> <? } ?> </select> <span id="ajax_mc2"> <? $mc_arr2 = TO_get_mc($regood_arr[1]['b_uid'],"","N"); ?> <select name="m_uid2" id="m_uid2" onchange="ajax_obj_loader('../good/good_edit_category_ajax2.html?mode=sc2&b_uid2=<?=$regood_arr[1]['b_uid']?>&m_uid2='+this.value,'ajax_sc2');"> <option value="" style="background:#000000;color:#ffffff;">==2차카테고리==</option> <? for($i=0 ;$i<count($mc_arr2) ;$i++){ $arr = $mc_arr2[$i]; ?> <option value="<?=$arr['m_uid']?>" <?=($regood_arr[1]['m_uid']==$arr['m_uid'])?"selected":""?>><?=$arr['m_name']?></option> <?}?> </select> </span><!-- 2차 카테고리 --> <span id="ajax_sc2"> <? $sc_arr2 = TO_get_sc($regood_arr[1]['b_uid'],$regood_arr[1]['m_uid'],"","N"); ?> <select name="s_uid2" id="s_uid2" onchange="ajax_obj_loader('../good/good_edit_category_ajax2.html?mode=good2&b_uid2=<?=$regood_arr[1]['b_uid']?>&m_uid2=<?=$m_uid2?>&s_uid2='+this.value,'ajax_good2');"> <option value="" style="background:#000000;color:#ffffff;">==3차카테고리==</option> <? for($i=0 ;$i<count($sc_arr2) ;$i++){ $arr = $sc_arr2[$i]; ?> <option value="<?=$arr['s_uid']?>" <?=($regood_arr[1]['s_uid']==$arr['s_uid'])?"selected":""?>><?=$arr['s_name']?></option> <?}?> </select> </span><!-- 3차 카테고리 --> <span id="ajax_good2"> <? $data_good2 = $CommonTour->listGoodHotel(array("b_uid"=>$regood_arr[1]['b_uid'],"m_uid"=>$regood_arr[1]['m_uid'],"s_uid"=>$regood_arr[1]['s_uid'])); ?> <select name="g_uid2" id="g_uid2" style="width:500px"> <option value="">=상품/호텔=</option> <? for($i=0 ;$i<count($data_good2) ;$i++){ $arr = $data_good2[$i]; ?> <option value="<?=$arr['g_uid']?>" <?=($regood_arr[1]['r_uid']==$arr['g_uid'])?"selected":""?>><?=$arr['g_title']?></option> <?}?> </select> <span onclick="GoodRelated('del');" style="cursor:pointer;">-</span> </span><!-- 상품 --> </td> </tr> <tr> <td> <input type="hidden" name="idx3" value="<?=$regood_arr[2]['idx']?>"> <input type="text" class="input_text" name="related_ordernum_arr3" value="<?=$regood_arr[2]['ordernum']?$regood_arr[2]['ordernum']:'3'?>" style="width:40px"> <select name="b_uid3" id="b_uid3" onchange="$('#ajax_sc3').html('');ajax_obj_loader('../good/good_edit_category_ajax2.html?mode=mc3&b_uid3='+this.value,'ajax_mc3');" style="width:140px;"> <option value="" style="background:#000000;color:#ffffff;">==1차카테고리==</option> <? for($i=0 ; $i<count($data_bc) ; $i++){ $arr = $data_bc[$i]; ?> <option value="<?=$arr['b_uid']?>" <?=($arr['b_uid']==$regood_arr[2]['b_uid'])?"selected":""?>><?=$arr['b_name']?></option> <? } ?> </select> <span id="ajax_mc3"> <? $mc_arr3 = TO_get_mc($regood_arr[2]['b_uid'],"","N"); ?> <select name="m_uid3" id="m_uid3" onchange="ajax_obj_loader('../good/good_edit_category_ajax2.html?mode=sc3&b_uid3=<?=$regood_arr[2]['b_uid']?>&m_uid3='+this.value,'ajax_sc3');"> <option value="" style="background:#000000;color:#ffffff;">==2차카테고리==</option> <? for($i=0 ;$i<count($mc_arr3) ;$i++){ $arr = $mc_arr3[$i]; ?> <option value="<?=$arr['m_uid']?>" <?=($regood_arr[2]['m_uid']==$arr['m_uid'])?"selected":""?>><?=$arr['m_name']?></option> <?}?> </select> </span><!-- 2차 카테고리 --> <span id="ajax_sc3"> <? $sc_arr3 = TO_get_sc($regood_arr[2]['b_uid'],$regood_arr[2]['m_uid'],"","N"); ?> <select name="s_uid3" id="s_uid3" onchange="ajax_obj_loader('../good/good_edit_category_ajax2.html?mode=good3&b_uid3=<?=$regood_arr[2]['b_uid']?>&m_uid3=<?=$m_uid3?>&s_uid3='+this.value,'ajax_good3');"> <option value="" style="background:#000000;color:#ffffff;">==3차카테고리==</option> <? for($i=0 ;$i<count($sc_arr3) ;$i++){ $arr = $sc_arr3[$i]; ?> <option value="<?=$arr['s_uid']?>" <?=($regood_arr[2]['s_uid']==$arr['s_uid'])?"selected":""?>><?=$arr['s_name']?></option> <?}?> </select> </span><!-- 3차 카테고리 --> <span id="ajax_good3"> <? $data_good3 = $CommonTour->listGoodHotel(array("b_uid"=>$regood_arr[2]['b_uid'],"m_uid"=>$regood_arr[2]['m_uid'],"s_uid"=>$regood_arr[2]['s_uid'])); ?> <select name="g_uid3" id="g_uid3" style="width:500px"> <option value="">=상품/호텔=</option> <? for($i=0 ;$i<count($data_good3) ;$i++){ $arr = $data_good3[$i]; ?> <option value="<?=$arr['g_uid']?>" <?=($regood_arr[2]['r_uid']==$arr['g_uid'])?"selected":""?>><?=$arr['g_title']?></option> <?}?> </select> <span onclick="GoodRelated('del');" style="cursor:pointer;">-</span> </span><!-- 상품 --> </td> </tr> <tr> <td> <input type="hidden" name="idx4" value="<?=$regood_arr[3]['idx']?>"> <input type="text" class="input_text" name="related_ordernum_arr4" value="<?=$regood_arr[3]['ordernum']?$regood_arr[3]['ordernum']:'4'?>" style="width:40px"> <select name="b_uid4" id="b_uid4" onchange="$('#ajax_sc4').html('');ajax_obj_loader('../good/good_edit_category_ajax2.html?mode=mc4&b_uid4='+this.value,'ajax_mc4');" style="width:140px;"> <option value="" style="background:#000000;color:#ffffff;">==1차카테고리==</option> <? for($i=0 ; $i<count($data_bc) ; $i++){ $arr = $data_bc[$i]; ?> <option value="<?=$arr['b_uid']?>" <?=($arr['b_uid']==$regood_arr[3]['b_uid'])?"selected":""?>><?=$arr['b_name']?></option> <? } ?> </select> <span id="ajax_mc4"> <? $mc_arr4 = TO_get_mc($regood_arr[3]['b_uid'],"","N"); ?> <select name="m_uid4" id="m_uid4" onchange="ajax_obj_loader('../good/good_edit_category_ajax2.html?mode=sc4&b_uid4=<?=$regood_arr[3]['b_uid']?>&m_uid4='+this.value,'ajax_sc4');"> <option value="" style="background:#000000;color:#ffffff;">==2차카테고리==</option> <? for($i=0 ;$i<count($mc_arr4) ;$i++){ $arr = $mc_arr4[$i]; ?> <option value="<?=$arr['m_uid']?>" <?=($regood_arr[3]['m_uid']==$arr['m_uid'])?"selected":""?>><?=$arr['m_name']?></option> <?}?> </select> </span><!-- 2차 카테고리 --> <span id="ajax_sc4"> <? $sc_arr4 = TO_get_sc($regood_arr[3]['b_uid'],$regood_arr[3]['m_uid'],"","N"); ?> <select name="s_uid4" id="s_uid4" onchange="ajax_obj_loader('../good/good_edit_category_ajax2.html?mode=good4&b_uid4=<?=$regood_arr[3]['b_uid']?>&m_uid4=<?=$m_uid4?>&s_uid4='+this.value,'ajax_good4');"> <option value="" style="background:#000000;color:#ffffff;">==3차카테고리==</option> <? for($i=0 ;$i<count($sc_arr4) ;$i++){ $arr = $sc_arr4[$i]; ?> <option value="<?=$arr['s_uid']?>" <?=($regood_arr[3]['s_uid']==$arr['s_uid'])?"selected":""?>><?=$arr['s_name']?></option> <?}?> </select> </span><!-- 3차 카테고리 --> <span id="ajax_good4"> <? $data_good4 = $CommonTour->listGoodHotel(array("b_uid"=>$regood_arr[3]['b_uid'],"m_uid"=>$regood_arr[3]['m_uid'],"s_uid"=>$regood_arr[3]['s_uid'])); ?> <select name="g_uid4" id="g_uid4" style="width:500px"> <option value="">=상품/호텔=</option> <? for($i=0 ;$i<count($data_good4) ;$i++){ $arr = $data_good4[$i]; ?> <option value="<?=$arr['g_uid']?>" <?=($regood_arr[3]['r_uid']==$arr['g_uid'])?"selected":""?>><?=$arr['g_title']?></option> <?}?> </select> <span onclick="GoodRelated('del');" style="cursor:pointer;">-</span> </span><!-- 상품 --> </td> </tr> <tr> <td> <input type="hidden" name="idx5" value="<?=$regood_arr[4]['idx']?>"> <input type="text" class="input_text" name="related_ordernum_arr5" value="<?=$regood_arr[4]['ordernum']?$regood_arr[4]['ordernum']:'5'?>" style="width:40px"> <select name="b_uid5" id="b_uid5" onchange="$('#ajax_sc5').html('');ajax_obj_loader('../good/good_edit_category_ajax2.html?mode=mc5&b_uid5='+this.value,'ajax_mc5');" style="width:140px;"> <option value="" style="background:#000000;color:#ffffff;">==1차카테고리==</option> <? for($i=0 ; $i<count($data_bc) ; $i++){ $arr = $data_bc[$i]; ?> <option value="<?=$arr['b_uid']?>" <?=($arr['b_uid']==$regood_arr[4]['b_uid'])?"selected":""?>><?=$arr['b_name']?></option> <? } ?> </select> <span id="ajax_mc5"> <? $mc_arr5 = TO_get_mc($regood_arr[4]['b_uid'],"","N"); ?> <select name="m_uid5" id="m_uid5" onchange="ajax_obj_loader('../good/good_edit_category_ajax2.html?mode=sc5&b_uid5=<?=$regood_arr[4]['b_uid']?>&m_uid5='+this.value,'ajax_sc5');"> <option value="" style="background:#000000;color:#ffffff;">==2차카테고리==</option> <? for($i=0 ;$i<count($mc_arr5) ;$i++){ $arr = $mc_arr5[$i]; ?> <option value="<?=$arr['m_uid']?>" <?=($regood_arr[4]['m_uid']==$arr['m_uid'])?"selected":""?>><?=$arr['m_name']?></option> <?}?> </select> </span><!-- 2차 카테고리 --> <span id="ajax_sc5"> <? $sc_arr5 = TO_get_sc($regood_arr[4]['b_uid'],$regood_arr[4]['m_uid'],"","N"); ?> <select name="s_uid5" id="s_uid5" onchange="ajax_obj_loader('../good/good_edit_category_ajax2.html?mode=good5&b_uid5=<?=$regood_arr[4]['b_uid']?>&m_uid5=<?=$m_uid5?>&s_uid5='+this.value,'ajax_good4');"> <option value="" style="background:#000000;color:#ffffff;">==3차카테고리==</option> <? for($i=0 ;$i<count($sc_arr5) ;$i++){ $arr = $sc_arr5[$i]; ?> <option value="<?=$arr['s_uid']?>" <?=($regood_arr[4]['s_uid']==$arr['s_uid'])?"selected":""?>><?=$arr['s_name']?></option> <?}?> </select> </span><!-- 3차 카테고리 --> <span id="ajax_good5"> <? $data_good5 = $CommonTour->listGoodHotel(array("b_uid"=>$regood_arr[4]['b_uid'],"m_uid"=>$regood_arr[4]['m_uid'],"s_uid"=>$regood_arr[4]['s_uid'])); ?> <select name="g_uid5" id="g_uid5" style="width:500px"> <option value="">=상품/호텔=</option> <? for($i=0 ;$i<count($data_good5) ;$i++){ $arr = $data_good5[$i]; ?> <option value="<?=$arr['g_uid']?>" <?=($regood_arr[4]['r_uid']==$arr['g_uid'])?"selected":""?>><?=$arr['g_title']?></option> <?}?> </select> <span onclick="GoodRelated('del');" style="cursor:pointer;">-</span> </span><!-- 상품 --> </td> </tr> </table> </td> </tr> </table> </form> <!-- /폼 --> <div class="btn_wrap_C pt30"> <a class="Bbtn red" onClick="edit_frm();" href="javascript:;">수정</a> <a href="hotel_list.html?<?=$_href?>" class="Bbtn gray">목록보기</a> </div> </div> </div> <script Language="javascript"> function edit_frm() { var f=document.frm_ins; // 폼체크 var result = to_validation(f); if (result == false) return false; console.log('duplicated checked is ' + $('#seoDuplicateCheckBtn').attr("isCheck")); if($('#seoDuplicateCheckBtn').attr("isCheck") != 'Y'){ alert('컨텐츠 URL 중복체크를 진행하세요.'); $('#seo_good_url').focus(); return false; } if(!confirm("수정하시겠습니까?")) return false; f.action = "hotel_proc.php?<?=$_href?>"; f.submit(); } function copy_url(url){ var temp_elem = document.createElement("textarea"); document.body.appendChild(temp_elem); temp_elem.value = url; temp_elem.select() temp_elem.setSelectionRange(0, 99999); /*For mobile devices*/ document.execCommand("copy"); document.body.removeChild(temp_elem); alert("클립보드에 링크 주소를 복사했습니다. 원하는 곳에 붙여넣기 하세요.\n\n" + url); return false; } //숙소등급이미지 var hotel_arr = Array(); <? for($i=0 ; $i < count($data_hotel) ; $i++){ ?> hotel_arr['<?=$data_hotel[$i]['code']?>'] = "<img src='<?=$data_hotel[$i]['cd_img']?>' alt='등급구분' />"; <?}?> $("#level_cd").bind("change",function(){ var code = $(this).val(); $('#hotel_level_img').html(hotel_arr[code]); }) //관광지코드 자동생성 $(function(){ $("#hotel_code_auto").bind("click",function(){ if($(this).is(":checked")==true){ $("input[name='hotel_code']").val("<?=$auto_str?>"); }else{ $("input[name='hotel_code']").val(""); } }); }) var review_pop = false; $(document).ready(function(){ // 카테고리 세팅 ajax_obj_loader('../good/good_edit_category_ajax.html?mode=mc&b_uid=<?=$rows['b_uid']?>&m_uid=<?=$rows['m_uid']?>','ajax_mc'); // 2차 카텍고리 ajax_obj_loader('../good/good_edit_category_ajax.html?mode=sc&b_uid=<?=$rows['b_uid']?>&m_uid=<?=$rows['m_uid']?>&s_uid=<?=$rows['s_uid']?>','ajax_sc'); // 3차 카테고리 $('#review_find_icon').click(function (){ var url = $('#review_url').val(); if(url=='') return; if(review_pop) review_pop.close(); review_pop = window.open('', 'review_pop'); review_pop.location.href = url; review_pop.focus(); }); $('#hotel_level_img').html(hotel_arr['<?=$rows['level_cd']?>']); ajax_obj_loader('../include/category_ajax.html?mode=bc&md=<?=$cf[md]?>&b_uid=<?=$b_uid?>','ajax_bc'); <?if($b_uid){?> ajax_obj_loader('../include/category_ajax.html?mode=mc&b_uid=<?=$b_uid?>&m_uid=<?=$m_uid?>','ajax_mc'); <?}?> $('#seoCategoryUrlAddBtn').click(function(){ $('#seoCategoryUrlFieldAdd').fadeIn('fast', function(){ $('#seoCategoryUrlRegBtn').fadeIn() }) }) //seo good url 중복체크 $('#seoDuplicateCheckBtn').click(function(){ seoCategoryDuplicateCheck(); }) $('#seo_second_category_url').change(function(){ $('#seoDuplicateCheckBtn').attr("isCheck", ""); //중복값 체크 if($(this).val() == $('#seo_first_category_url').val()){ $('#seo_second_category_url').val(''); alert('First URL과 다른 값을 선택하세요.'); } newUrlView(); }) $('#seo_good_url').keydown(function(){ $('#seoDuplicateCheckBtn').attr("isCheck", ""); }) $('#seo_good_url').keyup(function(){ newUrlView(); }) $('#seoCategoryUrlRegBtn').click(function(){ seoCategoryUrlReg() }) $('#seo_first_category_url').change(function(){ newUrlView(); }) $('#newUrlCopyBtn').click(function(){ copy_url($('#newUrlAddress').val()); }) $('#seoUrlInitBtn').click(function(){ if(confirm('외부에서 해당 URL로 접근할 수 없습니다. 진행하시겠습니까?')){ hseq = $(this).attr('hseq'); if(hseq){ seoUrlInit(hseq) } } }) }); function seoUrlInit(hseq){ if(!confirm('초기화 후 페이지가 새로고침됩니다. 진행하시겠습니까?')){ return false; } if(!hseq){ iziToast.show({ timeout:2000, color: 'red', title: 'SEO URL 초기화', message: "개발자에게 문의하세요.", }); } $.ajax({ type: "POST", url: "/toadmin/ajaxData/", data: {mode:'initSeoHotelUrl',hseq}, dataType: 'json', async:false, success: function (data) { console.log(JSON.stringify(data)); if(data.result == true){ iziToast.show({ timeout:2000, color: 'green', title: 'SEO URL 초기화', message: "완료되었습니다.", }); location.href = location.href; }else{ iziToast.show({ timeout:2000, color: 'red', title: 'SEO URL 초기화', message: data.errMsg, }); } }, error: function (e) { if(!guid){ iziToast.show({ timeout:2000, color: 'red', title: 'SEO URL 초기화', message: "개발자에게 문의하세요. - 500", }); } } }); } function seoCategoryUrlReg(){ seoCategoryUrl = $('#seoCategoryUrlFieldAdd').val(); $.ajax({ type: "POST", url: "/toadmin/ajaxData/", data: {mode:'inputSeoHotelCategoryUrl',seoCategoryUrl, ins_id:to_mb_id}, dataType: 'json', async:false, success: function (data) { console.log(JSON.stringify(data)); if(data.result == true){ if(data.isCreatingFolder == false){ iziToast.show({ timeout:5000, color: 'red', title: 'SEO URL', message: "폴더생성실패 개발자에게 문의하세요.", }); }else{ iziToast.show({ timeout:2000, color: 'green', title: 'SEO URL', message: "입력완료되었습니다.", }); } $('#seo_second_category_url').append($('<option>', { value: seoCategoryUrl, text: seoCategoryUrl })); $('#seo_second_category_url').val(seoCategoryUrl); $('#seoCategoryUrlFieldAdd').val(''); $('#seoCategoryUrlFieldAdd').fadeOut(); $('#seoCategoryUrlRegBtn').fadeOut(); }else{ iziToast.show({ timeout:2000, color: 'red', title: 'SEO URL', message: data.errMsg, }); } }, error: function (e) { } }); } function newUrlView(){ nowDomainUrl = $('#nowDomainUrl').val(); firstCategoryValue = $('#seo_first_category_url').val(); secondCategoryValue = $('#seo_second_category_url').val(); goodValue = $('#seo_good_url').val(); newUrl = nowDomainUrl+firstCategoryValue+'/'+secondCategoryValue+'/'+goodValue+'/'; $('#seoUrlAddress').text("새 URL : " + newUrl) $('#newUrlAddress').val(newUrl); $('#newUrlLink').attr('href',newUrl); } function seoCategoryDuplicateCheck(){ firstCategoryUrl = $('#seo_first_category_url').val(); secondCategoryUrl = $('#seo_second_category_url').val(); seoGoodUrl = $('#seo_good_url').val(); nowLang = $('#seoLang').val(); if(!firstCategoryUrl){ alert('First Category URL을 선택하세요.'); $('#seo_first_category_url').focus(); return false; } if(!secondCategoryUrl){ alert('Second Category URL을 선택하세요.'); $('#seo_second_category_url').focus(); return false; } if(!seoGoodUrl){ alert('url을 입력하세요.'); $('#seo_good_url').focus(); return false; } $.ajax({ type: "POST", url: "/toadmin/ajaxData/", data: {mode:'seoHotelDuplicateCheck', firstCategoryUrl, secondCategoryUrl, seoGoodUrl, nowLang}, dataType: 'json', async:false, success: function (data) { console.log(JSON.stringify(data)); if(data.result == true){ if(data.isDuplicate == true){ $('#seoDuplicateCheckBtn').attr("isCheck", ""); iziToast.show({ timeout:3000, color: 'red', title: 'SEO 상품 URL', message: "사용할 수 없습니다.", position:'bottomCenter', }); }else{ $('#seoDuplicateCheckBtn').attr("isCheck", "Y"); iziToast.show({ timeout:2000, color: 'green', title: 'SEO 상품 URL', message: "사용할 수 있습니다.", }); } }else{ iziToast.show({ timeout:2000, color: 'red', title: 'SEO 상품 URL', message: data.errMsg, }); } }, error: function (e) { iziToast.show({ timeout:5000, color: 'red', title: 'SEO 상품 URL ERROR', message: '개발자에게 문의하세요.', }); } }); } </script> <? include "../include/footer.html"; ?>