×

Welcome to TagMyCode

Please login or create account to add a snippet.
0
0
 
0
Language: PHP
Posted by: Fabian Morales
Added: Sep 19, 2015 9:52 PM
Views: 14
  1.     public function hacerLogin(){
  2.         $login = Input::get("login");
  3.         $clave = Input::get("password");
  4.         if (Auth::attempt(array('login' => $login, 'password' => $clave))){        
  5.             return Redirect::to("/")->with("mensaje", "Logueado");
  6.         }
  7.         else{
  8.             return Redirect::to("/sesion/formLogin")->with("mensajeError", "Correo o clave incorrecta");
  9.         }
  10.     }