Advertisement
Guest User

Untitled

a guest
Sep 20th, 2017
335
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.28 KB | None | 0 0
  1. $user = ORM::factory('user');
  2. $user->username = 'philisgay';
  3. $user->password = 'password';
  4. $user->passwords2 = 'passwordasdfadsf';
  5.  
  6. try
  7. {
  8.     $user->save();
  9. }
  10. catch(ORM_Validation_Exception $e)
  11. {
  12.     // Passwords don't match hence we are here
  13.     echo Debug::vars($e->errors('models');
  14. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement