Files
core/hwe/map_history.php
T
Hide_D e0cbf34d43 CheckLogin을 다시 구현.
- ajax 함수에서는 사용해선 안됨.
- 이외에선 index에서만 제대로 장수삭제처리를 하므로 문제 없을 것.
2018-04-03 03:05:26 +09:00

36 lines
657 B
PHP

<?php
namespace sammo;
$year = $_GET['year'];
$month = $_GET['month'];
$url = '/a_history.php';
if(!strpos($_SERVER['HTTP_REFERER'], $url)) {
exit(1);
}
if(!$year || !$month) {
exit(1);
}
include "lib.php";
include "func.php";
//로그인 검사
CheckLoginWithGeneralID();
$connect = dbConn();
$query = "select map from history where year='$year' and month='$month'";
$result = MYDB_query($query, $connect) or Error(__LINE__.MYDB_error($connect),"");
$history = MYDB_fetch_array($result);
if(!$history['map']) {
exit(1);
}
$map = $history['map'];
$map = str_replace('<_quot_>', "'", $map);
$map = str_replace('<_dquot_>', '"', $map);
echo $map;