Flexible CMS
Flexcms is simple and flexible yet powerful Laravel functionality.! It lets you build a page structure with lists and pages., (*1)
Every page can exist within the list or separately. You can build a blog with categories or a lonely contact page., (*2)
The most important thing is that you can have a page or a list with whatever url you like for example: - /my-page - /blog/super-category/super-post-with-extra-content - /contact - /about/company - /your/super/path/to/content, (*3)
Flexcms doesn't change any of the existing Laravel app. You don't even have to add anything to User model., (*4)
Every List or Page can have its own blade template., (*5)
Flexcms is ultra fast. Every Page and List is fully cached. No database request., (*6)
Laravel 5.6 with standard Authentication, (*7)
composer require jozwikp/flexcms
Add basic authentication, (*8)
php artisan make:auth
Add the ServiceProvider to the providers array in config/app.php, (*9)
Jozwikp\Flexcms\FlexcmsServiceProvider::class,
Add this line to the end of your routes/web.php, (*10)
Route::any('{path}', '\Jozwikp\Flexcms\controllers\PathController@resolve')->where('path', '(.*)');
Run migrations, (*11)
php artisan migrate
Add admin user with:, (*12)
$ php artisan flexcms:makeadmin
Flexcms use images to lists and pages so you should create a symbolic link from "public/storage" to "storage/app/public" with:, (*13)
$ php artisan storage:link
Login to your app and go to /flexcms, (*14)
Share the lists with the views in your AppServiceProvider.php boot() method, (*15)
$lists = Cache::rememberForever('lists', function() { return Liist::with('siblings')->whereNull('parent_id')->get(); }); view()->share('lists', $lists);
Include partials in your template (parent lists), (*16)
@include('flexcms::_lists')
or (parents with siblings), (*17)
@include('flexcms::_lists-siblings')
Publish the views, (*18)
php artisan vendor:publish
list-default.blade.php page-default.blade.php, (*19)
If you need other type of views you can copy default views and change default into other name. Use your new name while editing lists or pages., (*20)