install bundle VFouCmsBlogBundle via Composer :
composer require midnightcms/blog
in app/AppKernel.php :
$bundles = [ new VFou\Cms\BlogBundle\VFouCmsBlogBundle(), ]
in app/config/routing.yml :
# insert between vfou_cms_admin and vfou_cms_main vfou_cms_blog: resource: "@VFouCmsBlogBundle/Controller/" prefix: /midnightCMS type: annotation
Don't forget to update the schema :
php bin/console doctrine:schema:update --force
And install the assets :
php bin/console assets:install --symlink --relative
And clear the cache :
php bin/console cache:clear --env=prod
This extension will add the 'Blog' page type, a new toolbar menu labelled "Manage Blogs" and two templates into your MidnightCMS backend.
- Into the "Manage Blogs" tab you can create new blogs and manage posts into them.
- In the Page tab when you select "Blog" into page type you can select which blog you want to be attached to the page.
- The two templates are for the index view and the detail view of the blog. Every variables you can use will be commented on top of these templates file.
This bundle is under the MIT license. See the complete license in the bundle
Icons credit :
- Blog icon made by Freepik from www.flaticon.com