Exemple #1
0
                 $homeController->usernameCheck();
                 break;
             case 'emailCheck':
                 $homeController->emailCheck();
                 break;
             default:
                 $homeController->render();
                 break;
         }
     } else {
         $homeController->render();
     }
     break;
 case "completeProfile":
     if (isset($_SESSION["user_id"])) {
         $completeProfileController = new CompleteProfileController();
         $completeProfileController->render();
         break;
     }
 default:
     if (isset($_SESSION["user_id"])) {
         $dashboardController = new DashboardController();
         if ($route[2] == 'activities') {
             $dashboardController->getNextActivities();
         } elseif ($route[2] == 'postActivity') {
             $dashboardController->postActivity();
         } else {
             $dashboardController->render();
         }
         break;
     } else {
Exemple #2
0
                 $homeController->render();
                 break;
         }
     } else {
         $checkNewRoute = explode("=", $route[2]);
         if ($checkNewRoute[0] == 'usernameCheck') {
             $homeController->usernameCheck(urldecode($checkNewRoute[1]));
         } elseif ($checkNewRoute[0] == 'emailCheck') {
             $homeController->emailCheck(urldecode($checkNewRoute[1]));
         } else {
             $homeController->render();
         }
     }
     break;
 case "completeProfile":
     $completeProfileController = new CompleteProfileController();
     if ($route[2] == "finish") {
         $completeProfileController->finishCompleteProfile();
         break;
     }
     if (isset($_SESSION["user_id"])) {
         $completeProfileController->render();
         break;
     }
 default:
     $recoverPasswordReq = explode('?', $page);
     if ($recoverPasswordReq[0] == "forgetPassword") {
         //var_dump($recoverPasswordReq); die();
         $recoverPasswordController = new RecoverPasswordController();
         //$routeHashKeyCheck = explode('?', $recoverPasswordReq[1]);
         //var_dump($routeHashKeyCheck); die();