Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/vrkansagara/laravel-wordpress

Laravel module using WordPress as the backend API
https://github.com/vrkansagara/laravel-wordpress

blog laravel module wordpress

Last synced: 2 days ago
JSON representation

Laravel module using WordPress as the backend API

Awesome Lists containing this project

README

        

# Laravel WordPress

Need to set up following things in to .env file

VRKANSAGARA_LARAVEL_WORDPRESS_ENABLED=true
DB_WOREDPRESS_PREFIX='wp_'
DB_WOREDPRESS_CONNECTION='mysql-wordpress'
DB_WORDPRESS_DATABASE='wordpress'
DB_WORDPRESS_USERNAME='${DB_USERNAME}'
DB_WORDPRESS_PASSWORD='${DB_PASSWORD}'

### How to use it

getPosts()->get();
foreach ($posts as $k => $post){
echo $post->name;
echo $post->description;
echo $post->title;
echo $post->content;
}


#Note

DB_WOREDPRESS_CONNECTION key must not conflicts with other database key.