// THIS IS FROM loginController.php
public function loginUserAction()
{
$loginObj = FT\LoginFactory::CreateLogin("RegularLogin");
$username = $_POST["UserName"];
$password = $_POST["Password"];
if($loginObj->authenticateUser($username, $password))
{
$this->response->redirect("main/proceed");
// I've tried diffeent permutations of the following
// $this->view->disable();
// return false;
}
else{
throw new \Exception("Could not log in with provided credentials.");
}
}
// THIS IS FROM mainController.php
public function proceedAction()
{
echo "<h2>This is the proceed Action</h2>";
}
public function route404Action()
{
echo "<h1>COULD NOT FIND EXPECTED ACTION/VIEW</h1>";
}
// THE EXPECTED RESULT IS:
"This is the proceed Action" -- (The echo from the "proceedAction")
// THE ACTUAL RESULT IS:
"COULD NOT FIND EXPECTED ACTION/VIEW" -- (The echo from the "route404Action")
// THE LIFE CYCLE OF THIS PROCESS after calling $this->response->redirect("main/proceed"):
It goes through the bootstrap "index.php" file in the "public" folder twice:
-- The first time of $application->handle->getContent() is: "This is the proceed action"
-- The second time is: "COULD NOT FIND EXPECTED ACTION/VIEW" and that is the end.
Any suggestion as to why it's doing this instead of just redirecting where it should?