The blank return is probably caused by a php error ? is display errors turned on on php ? check your log.
You will need to change the validation rules and the create call at /app/Services/Registrat.php change table and fillable attributes in the User model
i am not sure what laravel does internally but
Auth::attempt(['username' => 'admin', 'password' => 'admin', 'active' => 1])
shouldnt you be doing
Auth::attempt(['useName' => 'admin', 'usePassword' => 'admin', 'active' => 1])
Probably, but all the error logs are clean. I'm running the the laravel app on vagrant homestead service and I've checked both the following logs:
/var/log/php5-fpm.log
/var/log/nginx/mysite.local-error.log
as well as the laravel log folder and none of them contain any errors. Are there any places I can look?
I believe that changes to the Registrat.php file is first required when I enable new users to register? Right now I'm just adding users via a standardized seeder class.
shez1983 - I've tried those changes, but all I still get is just the blank laravel screen of death :E
So - I've taken the liberty of starting over and checking out Laravel 5.0.* fresh (yes, 5.0, not 5.1 as the server I am on won't be upgrading for a little bit). Then I slowly started changing the database in the way I would like.
I've managed to get everything working fine with just changing the table name from 'users' to 'tblUser'. Everything is great!
However - having changed the 'password' field to 'usePassword' has thrown a wrench into the work. Basically, the default login.blade.php file now keeps complaining that the password field is required.
I snooped some more and discovered that the validation actually takes place in the 'AuthenticatesAndRegistersUsers.php' file. I fixed this but still seemed to run into the 'password field is required' error.
It took me a while to figure out that I needed to clear laravels compiled.php by writing 'php artisan clear-compiled' which solved this error.
Now I'm on to the problem of Laravel telling me that the credentials do not match the records. I wonder if I have to meddle more, possibly in the 'EloquentUserProvider.php' - however the link I provided earlier has a discussion regarding this matter who claims Laravel should search for a suitable password field on its own.
I really would like to use the name 'usePassword' as the field name, so if anyone has any ideas for how to cleanly make this work, I'm all ears.
Gazoo
It took me the better part of a day or so and a visit to the helpful people at the Laravel channel on IRC, but I finally found out how to do it. A complete step-by-step solution is provided here:
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community