세션 시작 방식을 Session 클래스를 이용하도록 변경

This commit is contained in:
2018-04-01 00:28:55 +09:00
parent 0b584c7b0d
commit 3ea95da4a6
6 changed files with 80 additions and 70 deletions
+10 -8
View File
@@ -3,15 +3,17 @@ namespace sammo;
function CheckLogin($type=0) {
if(!isset($_SESSION['userID'])) {
if($type == 0) {
header('Location: ../');
}
else {
header('Location: index.php');
}
exit();
//TODO: 직접해라. setReadOnly() 호출이 필요하다.
if(Session::Instance()->loginGame()->generalID){
return;
}
if($type == 0) {
header('Location: ../');
}
else {
header('Location: index.php');
}
exit();
}