1

I changed some fields in users database table. table name: users primaryKey: user_id username: user_username password: user_password e-mail: user_mail

I updated login.blade.php to this:

<form method="POST" action="/auth/login">
{!! csrf_field() !!}

<div>
    Username
    <input type="user_username" name="user_username" value="{{ old('user_username') }}">
</div>

<div>
    Password
    <input type="password" name="password" id="password">
</div>

<div>
    <input type="checkbox" name="remember"> Remember Me
</div>

<div>
    <button type="submit">Login</button>
</div>

in Illuminate\Foundation\AuthAuthenticatesUsers I added protected $username = 'user_username';

When i try login to my account when i handed username and password i see blank page. Debug is on but not working. What happend?

Pionas
  • 346
  • 1
  • 4
  • 15
  • 1
    If debug is on but now working, you'd better check the error logs. But if you happily changed the password field in the database and didn't tell Laravel, I guess that's the source of the error, and maybe you can find how to fix that here: http://stackoverflow.com/questions/26073309/how-to-change-custom-password-field-name-for-laravel-4-and-laravel-5-user-auth – Amarnasan Sep 01 '15 at 08:26
  • Thanks. My mistake. i moved User class to User\User. I edited auth.php and now it's working. Thanks for helping – Pionas Sep 01 '15 at 09:02

1 Answers1

0

I have one problem. I try to log on my account but i can't do this. It's blank page.

Auth::attempt(array(
            'user_username' => 'pionas',
            'user_password'  => '12345',
        ));

I User model i add getAuthPassword and change column name to user_password. Log is clear...

Pionas
  • 346
  • 1
  • 4
  • 15