PHP 클래스 LoginController, huge

상속: extends Controller
파일 보기 프로젝트 열기: panique/huge 1 사용 예제들

공개 메소드들

메소드 설명
__construct ( ) Construct this object by extending the basic Controller class. The parent::__construct thing is necessary to put checkAuthentication in here to make an entire controller only usable for logged-in users (for sure not needed in the LoginController).
index ( ) Index, default action (shows the login form), when you do login/index
login ( ) The login action, when you do login/login
loginWithCookie ( ) Login with cookie
logout ( ) The logout action Perform logout, redirect user to main-page
requestPasswordReset ( ) Show the request-password-reset page
requestPasswordReset_action ( ) The request-password-reset action POST-request after form submit
setNewPassword ( ) Set the new password Please note that this happens while the user is not logged in. The user identifies via the data provided by the password reset link from the email, automatically filled into the
fields. See verifyPasswordReset() for more. Then (regardless of result) route user to index page (user will get success/error via feedback message) POST request ! TODO this is an _action
verifyPasswordReset ( string $user_name, string $verification_code ) Verify the verification token of that user (to show the user the password editing view or not)

메소드 상세

__construct() 공개 메소드

Construct this object by extending the basic Controller class. The parent::__construct thing is necessary to put checkAuthentication in here to make an entire controller only usable for logged-in users (for sure not needed in the LoginController).
public __construct ( )

index() 공개 메소드

Index, default action (shows the login form), when you do login/index
public index ( )

login() 공개 메소드

The login action, when you do login/login
public login ( )

loginWithCookie() 공개 메소드

Login with cookie
public loginWithCookie ( )

logout() 공개 메소드

The logout action Perform logout, redirect user to main-page
public logout ( )

requestPasswordReset() 공개 메소드

Show the request-password-reset page

requestPasswordReset_action() 공개 메소드

The request-password-reset action POST-request after form submit

setNewPassword() 공개 메소드

Set the new password Please note that this happens while the user is not logged in. The user identifies via the data provided by the password reset link from the email, automatically filled into the fields. See verifyPasswordReset() for more. Then (regardless of result) route user to index page (user will get success/error via feedback message) POST request ! TODO this is an _action
public setNewPassword ( )

verifyPasswordReset() 공개 메소드

Verify the verification token of that user (to show the user the password editing view or not)
public verifyPasswordReset ( string $user_name, string $verification_code )
$user_name string username
$verification_code string password reset verification token