- Session클래스 내에서 global setter, getter 재정의 - Session클래스에서 static 함수로 getUserID, getUserGrade 재정의 - 내부 서버에서 getUserID, getUserGrade를 쓰던 것 Session 클래스로 통일 - SESSION.php가 requireLogin 기능을 수행하던것을 Session의 static 함수로 통합
30 lines
668 B
PHP
30 lines
668 B
PHP
<?php
|
|
namespace sammo;
|
|
|
|
include "lib.php";
|
|
include "func.php";
|
|
|
|
//TODO: 이게 뭔지 분석
|
|
|
|
$btn = $_POST['btn'];
|
|
$userID = Session::getUserID();
|
|
$connect = dbConn(true);
|
|
|
|
//회원 테이블에서 정보확인
|
|
$query = "select no,name,picture,grade from MEMBER where no='$userID'";
|
|
$result = MYDB_query($query, $connect) or Error(__LINE__.MYDB_error($connect),"");
|
|
$member = MYDB_fetch_array($result);
|
|
|
|
if(!$member) {
|
|
MessageBox("잘못된 접근입니다!!!");
|
|
echo "<script>history.go(-1);</script>";
|
|
exit(1);
|
|
}
|
|
|
|
|
|
|
|
if($btn == "장수생성") {
|
|
header('Location:join.php');
|
|
} elseif($btn == "장수선택") {
|
|
header('Location:select_npc.php');
|
|
} |