Tryag File Manager
Home
||
Turbo Force
||
B-F Config_Cpanel
Current Path :
/
home
/
egg.eemo.co.kr
/
public_html
/
super5
/
Or
Select Your Path :
Upload File :
New :
File
Dir
/home/egg.eemo.co.kr/public_html/super5/rank_event_mody_do.php
<? session_cache_limiter('no-cache, must-revalidate'); session_start(); header("Pragma: no-cache"); header("Cache-Control: no-cache,must-revalidate"); header("Content-Type: text/html; charset=utf-8"); foreach($_POST as $key => $value) { ${$key}=trim($value); } if(!$_SESSION[mem_id]) { echo "<script>alert('권한이 없습니다.');history.back();</script>"; exit; } include_once("dbconn.php"); include_once("lib.php"); ini_set('max_execution_time',86400); if($sel_week) { $exp=explode("-",$sel_week); $eYYYY=$exp[0]; $eMM=$exp[1]; $eJU=$exp[2]; $syear=$eYYYY-1; $eyear=$eYYYY+1; $arr_jucha=array(); for($y=$syear;$y<=$eyear;$y++) { for($m=1;$m<=12;$m++) { $LastDay=date("t",mktime(0,0,1,$m,1,$y)); for($d=1;$d<=$LastDay;$d++) { $v_date=date("Y-m-d",mktime(0,0,1,$m,$d,$y)); $jdate=$v_date; //if($jdate > date('Y-m-d')) {continue;} //주차 구하기 $rtn_date=get_startday_endday($jdate); $exp_date=explode("~",$rtn_date); $start_date=$exp_date[0]; $end_date=$exp_date[1]; $league_code = getWeekInfo($start_date); $exp_ww=explode("/",$league_code); $YYYY=$exp_ww[0]; $MM=sprintf("%02d",$exp_ww[1]); $jucha=$exp_ww[2]; $arr_jucha[$YYYY."-".$MM."-".$jucha]=$start_date."~".$end_date; } } } krsort($arr_jucha); $gigan=''; foreach($arr_jucha as $ak => $av) { $exp_dd=explode("-",$ak); $YYYY=$exp_dd[0]; $MM=$exp_dd[1]; $jucha=$exp_dd[2]; $exp_dd2=explode("~",$av); if($YYYY."-".$MM."-".$jucha==$eYYYY."-".$eMM."-".$eJU) { $gigan=$av; $gigan_sdate=$exp_dd2[0]; $gigan_edate=$exp_dd2[1]; } } } else { $eYYYY=substr($sel_month,0,4); $eMM=substr($sel_month,4,2); $gigan_sdate=$eYYYY."-".$eMM."-01"; $LastDay=date("t",strtotime($gigan_sdate)); $gigan_edate=$eYYYY."-".$eMM."-".$LastDay; } $query="update rank_event set emode='$sel_mode', jyear='$eYYYY', jmonth='$eMM', jweek='$eJU', gigan_sdate='$gigan_sdate', gigan_edate='$gigan_edate', target_rank='$target_rank', view_link_url='$view_link_url', sangpum='$sangpum', regdate=now() where no='$no' "; mysql_query($query) or die(mysql_error()); echo "<meta http-equiv='refresh' content='0;url=rank_event.php?c_page=$c_page&find=$find&search=$search'>"; ?>