#4 Make Admin Panel in Laravel 5.6 | Default Laravel Login process with Laravel Migration

preview_player
Показать описание

In Part 4, We have configured default Laravel login process by using Laravel Migration.

Laravel Migrations provide us the mechanism for creating and modifying database tables.

So in video, we have created database first, then created users table with "php artisan migrate" command and then register/login with it. Later on we will use Matrix Admin login in this process.

1) Create Database :- We have first created database with name 'Sample'.

2) Update .env file :- Now we have updated .env file to configure our database connection.

3) Create Users table :- Now we have run some commands to create users table in database and then will create login/register pages also with another auth related command.

i) php artisan migrate

Run this command to create users table. If it gives error then check your database settings that you have given in .env file.

After running this command, Migration tables automatically created in which users table also there.

Now we will run another command :-

ii) php artisan make:auth

This command will create default login/register pages that we will later use for our admin Matrix login.

If some error comes in the process then do search on Google for it.. If homestead user error comes to you then make sure to clear your Laravel cache by below command :-

php artisan config:clear

and then restart Laravel and run php artisan serve command again to run it. It will work fine then.

See in video, we able to login/register successfully with the default login/register process of Laravel that we have configured.

In Part 5, we will embed this login system in Matrix Login. We will use the users table for it that we have created and will also add one more column for admin/users.

So stay tune for next video.

Thank you for watching :)

Рекомендации по теме
Комментарии
Автор

great video. you are great silent teacher.

loverphp
Автор

you such a great teacher, thankyou, thankyou...thankyou you 1 millontimes!

jhoanmartinezsilva
Автор

sou brasileiro e estou gostando baste de acompanhar esses videos obrigado e ótimo trabalho .

josealvaro
Автор

Nice and very clear video.. Thanks a lot

manjeetverma
Автор

Oh man, you are really awesome. Keep it up. It helped me a lot. Great tutor. Thank you:)

sumbalamjad
Автор

amit vaiya keep it up.i like your tutorials

md.akib
Автор

As outlined in the Migrations guide to fix this all you have to do is edit your AppServiceProvider.php file and inside the boot method set a default string length:

use

public function boot()
{

}

codecolic
Автор

i made it Multiauth with localization now how to do i shall see your next video .. Good AA ji

karajsadhak
Автор

If you will encounter the error "max key length is 767 bytes after hitting the php artisan migrate, try this:

go to AppServiceProvider.php and then include these codes:
use (at the top)
and inside the public function boot, add this:




and then drop the all the tables from your database in your phpmyadmin and then hit php artisan migrate again.
Hope this helps!

angeloavenido
Автор

After changing .env file always restart server using php artisan serve.

DVK
Автор

If you are using the PHP's default web server (e.g. php artisan serve) you need to restart your server after changing your .env file values.

codecolic
Автор

Hi you need only restart the server and evrything works fine ;) not neceseraly to use "php artisan config:clear"

WoTkURLAND
Автор

I can't do php artisan make:auth.. it doesn't exit. How to solve this issue. I am using Laravel 5.6. so I did ui:auth. It gives not designed page but it's working.. I need design default login page with design as you used like make:auth.. please solve this one

senthilkumar-fotr
Автор

Hallo my dear thanks a lot for all... Have an ReflectionException when i want register a user

tutos-et-astuces
Автор

Hi. I've got this error when run php artisan migrate:
: could not find driver (SQL: select * from information_schema.tables where table_schema = project1 and table_name = migrations)

at
660| // If an exception occurs when attempting to run a query, we'll format the error
661| // message to include the bindings with SQL, which will make this exception a
662| // lot more helpful to the developer instead of just the database's errors.
663| catch (Exception $e) {
> 664| throw new QueryException(
665| $query, $this->prepareBindings($bindings), $e
666| );
667| }
668|

Exception trace:

1 PDOException::("could not find driver")


2 PDO::__construct()

Can you please help me @@ Thanks so much

imwinprn
Автор

before php artisan make:auth you have to solve laravel 1071 error use and

mrenalkanti
Автор

hello sir, register login home page works but no design layout is shown as yours I m using laravel 6 ....please suggest what to do to get those page layouts

sambitpati
Автор

Why you don't create register form on the admin panel matrix? Because I'm confused there are two websites, Laravel and Matrix. Can you give us explain the different about Laravel site...

rudiyanto
Автор

Sir i have some error on git bash
the error like this


$ php artisan migrate
Migration table created successfully.

: SQLSTATE[42000]: Syntax error or access violation: 1071 Specified key was too long; max key length is
767 bytes (SQL: alter table `users` add unique

at
660| // If an exception occurs when attempting to run a query, we'll format the error
661| // message to include the bindings with SQL, which will make this exception a
662| // lot more helpful to the developer instead of just the database's errors.
663| catch (Exception $e) {
> 664| throw new QueryException(
665| $query, $this->prepareBindings($bindings), $e
666| );
667| }
668|

Exception trace:

1 Syntax error or access violation: 1071 Specified key was too long; max key length is 767 bytes")


2 PDOStatement::execute()


Please use the argument -v to see more details.

can you help me?

febrianvalentino
Автор

can this app development be done with laravel 5.5?

kingsleyakatakpo