| @@ 640-658 (lines=19) @@ | ||
| 637 | ||
| 638 | $logged = $this->forward()->dispatch('playgrounduser_user', array('action' => 'ajaxauthenticate')); |
|
| 639 | ||
| 640 | if (!$logged) { |
|
| 641 | $this->flashMessenger()->setNamespace('zfcuser-login-form')->addMessage( |
|
| 642 | 'Authentication failed. Please try again.' |
|
| 643 | ); |
|
| 644 | ||
| 645 | return $this->redirect()->toUrl( |
|
| 646 | $this->frontendUrl()->fromRoute( |
|
| 647 | $this->game->getClassType() . '/login', |
|
| 648 | array('id' => $this->game->getIdentifier()) |
|
| 649 | ) |
|
| 650 | ); |
|
| 651 | } else { |
|
| 652 | return $this->redirect()->toUrl( |
|
| 653 | $this->frontendUrl()->fromRoute( |
|
| 654 | $this->game->getClassType() . '/' . $this->game->nextStep('index'), |
|
| 655 | array('id' => $this->game->getIdentifier()) |
|
| 656 | ) |
|
| 657 | ); |
|
| 658 | } |
|
| 659 | } |
|
| 660 | ||
| 661 | $form->setAttribute( |
|
| @@ 838-855 (lines=18) @@ | ||
| 835 | ||
| 836 | $logged = $this->forward()->dispatch('playgrounduser_user', array('action' => 'ajaxauthenticate')); |
|
| 837 | ||
| 838 | if ($logged) { |
|
| 839 | return $this->redirect()->toUrl( |
|
| 840 | $this->frontendUrl()->fromRoute( |
|
| 841 | $this->game->getClassType() . '/' . $this->game->nextStep('index'), |
|
| 842 | array('id' => $this->game->getIdentifier()) |
|
| 843 | ) |
|
| 844 | ); |
|
| 845 | } else { |
|
| 846 | $this->flashMessenger()->setNamespace('zfcuser-login-form')->addMessage( |
|
| 847 | 'Authentication failed. Please try again.' |
|
| 848 | ); |
|
| 849 | return $this->redirect()->toUrl( |
|
| 850 | $this->frontendUrl()->fromRoute( |
|
| 851 | $this->game->getClassType() . '/login', |
|
| 852 | array('id' => $this->game->getIdentifier()) |
|
| 853 | ) |
|
| 854 | ); |
|
| 855 | } |
|
| 856 | } |
|
| 857 | ||
| 858 | $redirect = $this->frontendUrl()->fromRoute( |
|