-
Composer Install -> installing dependencys package
-
Rename .env.example to .env
-
set .env :
make sure you have created the database, and then change the code below according to your databaseDB_CONNECTION=mysql
DB_HOST=localhost
DB_PORT=3306
DB_DATABASE=database_name
DB_USERNAME=username
DB_PASSWORD=password -
php artisan migrate -> migrate model
-
php artisan db:seed -> auto adding data to table from seed -> seed is data permanent/default
-
php artisan key:generate -> generate the APP_KEY
-
php artisan serve -> run server
- CRUD
- Validation
- Paginate
- Middleware
- Post Edit/Delete Access
- composer require intervention/image -> make sure you have been installed GD library
> Code in UserController.php
> In view just call {{ auth()->user()->avatar }}
- In config/filesystem.php
- Code in UserProfileController
> change local setting to :
'local' => [
'driver' => 'local',
'root' => public_path('files'),
],