- Forums
- laravel
- Laravel Fully Functional And Complete Application With Spatie Media Library Api
This Page Contains information about Laravel Fully Functional And Complete Application With Spatie Media Library Api By jj in category laravel with 0 Replies. [5146], Last Updated: Mon Jun 24, 2024
jj
Sat Jun 03, 2023
0 Comments
284 Visits
Fast Version
First Set of Commands:
git clone https://github.com/codewithtonyofficial/laravel-medialibrary.git laravel-medialibraryV2
cd laravel-medialibraryV2
composer install
code .
cp .env.example .env; code .env
Create database and update env file:
APP_URL=http://localhost:8000
DB_DATABASE=[DATABASE NAME]
DB_USERNAME=root
DB_PASSWORD=
Second Set of Commands:
php artisan storage:link
php artisan migrate
php artisan key:generate
php artisan serve
Detailed Version
Follow these steps to have a complete Laravel Application with Spatie Media Library fully functional open source website.
- $ git clone https://github.com/codewithtonyofficial/laravel-medialibrary.git laravel-medialibraryV2
- $ cd laravel-medialibraryV2
- $ composer install
- $ code .
- $ cp .env.example .env; code .env
- Create a database to connect. for example, mysql with phpmyadmin
- update the following env file:
APP_URL=http://localhost:8000
DB_DATABASE=[DATABASE NAME]
DB_USERNAME=root
DB_PASSWORD=
- $ php artisan storage:link
- $ php artisan migrate
- $ php artisan key:generate
- $ php artisan serve
- open browser to http://127.0.0.1:8000/posts/create
- Done
Resources:
- https://stackoverflow.com/questions/50395449/laravel-image-saved-in-storage-folder-not-showing-to-user
- https://laravel.com/docs/9.x/filesystem#the-public-disk
- https://laracasts.com/discuss/channels/laravel/spatie-media-library-issue-with-geturl-method?reply=730889
- https://stackoverflow.com/questions/55474258/how-to-install-enable-gd-in-xampp-windows-php-7-2