Build a simple blog platform, that allow registered users could CRUD their posts and find me job view others. Admin is required to publish users’ posts.
what is application?
- People could register for new account and login/logout to the system
- Registered users could CRUD their posts.
- Posts’ body understand markdown syntax and could render properly
- Admin could see a list of created posts
- Admin could publish or unpublish created posts
- Only published posts would be display in public listing page
- Admin could see highlighting unpublished posts in list of all posts
- Admin could filter/order posts by date or status
- Admin could schedule post publishing. E.g найти работу I want publish this post automatically in tomorrow 9AM
-
Softwares: Installed PHP, Mysql, Laravel
-
Download source code and add .env file to blog directory. Config .env file follow as :
2.1 Connect with MySQL database
* DB_HOST=localhost * DB_DATABASE=your_database_name * DB_USERNAME=database_username * DB_PASSWORD=database_password
2.2 Add admin (default):
* INITIAL_USER_NAME=Admin * [email protected] * INITIAL_USER_PASSWORD=Admin@123 * INITIAL_USER_ROLE=admin
- users (default + role)
- posts (id, author_id, title, body, slug, active, published_at)
If you want to get this up and running quickly, follow these instructions:
- Clone the repository
git clone https://github.com/thanhth85/simple_blog_platform
- Follow the Setup database which includes:
- Edit the .env.example file to match your database and rename to .env
- Run the migrations : php artisan migrate:refresh --seed
-
run
composer install
andnpm install
-
Ensure that the permissions on the storage folder are set correctly. You will get a 500 error otherwise.
-
Ensure that you have set the correct image path for justboil.me to the appropriate folder or just use the default /images and make sure that folder has the correct permissions to upload images (usually owned by the webserver user).
-
php artisan serve ( run server )