Inherited Variables
Inherited Constants
Inherited Methods
Class: AbstractController
- AbstractController::__construct()
- class constructor
- AbstractController::index()
- index
Class Details
Handles login and logout requests, and user registration.
Tags:
- author - Monte Ohrt
- see - Login_Controller::register()
- see - Login_Controller::logout()
- see - Login_Controller::login()
[ Top ]
Class Variables
Class Methods
index
void index(
)
[line 19]
The default action. Defaults to login()
Tags:
Overrides AbstractController::index() (index)
Parameters:
[ Top ]
login
void login(
string
$username, string
$password, string
$redirect, bool
$json)
[line 30]
Logs the user in.
Parameters:
- string $username - The username to log in with.
- string $password - The password to log in with should match $username's password.
- string $redirect - The page to redirect to when finished. If left blank, redirects to default controller.
- bool $json - Specifies that we want JSON-style output. Used for AJAX calls. Defaults to false.
[ Top ]
logout
void logout(
string
$redirect, bool
$json)
[line 78]
Logs the current user out.
Parameters:
- string $redirect - The page to redirect to when finished. If left blank, redirects to the default page.
- bool $json - Specifies that we want JSON-style output. Used for AJAX calls. Defaults to false.
[ Top ]
register
void register(
string
$username, string
$password, string
$redirect)
[line 106]
Registers the user with the given information.
Parameters:
- string $username - The desired username.
- string $password - The desired password.
- string $redirect - Where to redirect after registration complete. If not specified, uses default controller.
[ Top ]