Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $user = new User();
- $login = $user->login(Input::get('username'), Input::get('password'));
- public function login($username = null, $password = null) {
- $user = $this->find($username);
- print_r($this->_data);
- if($user) {
- if ($this->data()->password === Hash::make($password, $this->data()->salt)) {
- echo 'OK!';
- } else {
- echo '<br>';
- echo 'This data password:';
- var_dump($this->data()->password);
- }
- }
- return false;
- }
- Array ( [0] => stdClass Object (
- [id] => 32
- [email] => xxx
- [fname] => xxx
- [lname] => xxx
- [username] => user
- [password] => 295c7ac2341f2688838148728d450a5562933d5fbea6d2a9e9fec2eeab29dd84
- [salt] => 4ÌxÇd”0ð&ÞðÈßr¡–k$ «%•¦S?~d$r
- [name] => xxx
- [joined] => 2016-09-28 07:10:32
- [grouptype] => 1 ) )
- Array ( [0] => stdClass Object
- stdClass Object ( [id] =>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement