Api based content managment system

This package's canonical repository appears to be gone and the package has been frozen as a result.

v1.0 2017-04-11 09:14 UTC

This package is not auto-updated.

Last update: 2019-02-20 20:08:20 UTC


README

API package for custom CMS.

Install it with: composer require "splendex/cms:dev-master". Then php artisan vendor:publish. This will create it's basic routes. In the .env file you will need:

SPLENDEX_API_URL= (the url which the data is coming from) SPLENDEX_API_KEY= (api key connecting the database to it) BLOG_PREFIX= (this will decide the prefix of you blog routes)

You can edit the view files of the blog (they can be found in resources/views/blog). You can create new api calls using this function : apiCall(env('SPLENDEX_API_URL') . '/api/xyz);

Api routes: /posts - all posts paginated /posts/specific - parameterized posts (url params: sort: param one is the cloumn param two is the order (sort=id,desc), category: one parameter category_id of the post (category=12), date: param one is the start, param two is the end date, date field in the posts: concert date etc. (date=start_date,end_date), count: the amount of posts that you want (count=10) /posts/{slug} - returns one post based on its slug

/categories : all categories /categories/{slug}: returns one category based on its slug

/events - all events /events/specific - parameterized events (same as for posts) /events/{slug}- returns one event based on its slug

/pages/{slug} - returns one page based on its slug

/menus - returns all menus and their subpages

/downloads - all dowloadable file from filemanager /downloads/{slug} - returns one downloadable file based on its slug

/galleries - all galleries /galleries/{slug} - returns one gallery based on its slug and its images