When writing articles on Habré, I noticed that the deceased Kohana framework was not to many people, and I heard a lot of criticism of the project for this reason and thought about the question: “
How to be and what to do with Kohana? “, Because the framework does not contribute to the development of CMS throughout the year.
The first thoughts were about the continuation of the development of Kohana on its own. First of all, Composer was integrated into the system, modules and plugins migrated to packages in the repository
https://packagist.org/packages/kodicms/ and the package types
https://github.com/composer/installers were added to the composer installer. After this, having spent some time searching, I came across the Kohana54 project (
https://github.com/kohana54/core ), the developer of which decided to bring all the classes into conformity with the PSR-4 standard, but apparently left to better times. At first, it didn’t worry me much, you could try to finish it for him, but after a few days I realized that in addition to the kernel itself, I would have to rewrite the rest of the standard framework modules as well as all the CMS modules, which is equivalent to using another, more modern framework and decided to finally tie it up with Kohana.
')
There was a question: “Which framework to choose?”
- Laravel
- FuelPHP
- Symfony
- Yii2
- Zend Framework 2
- Cakephp
Comparing frameworks can pull on a whole article, so I’ll confine myself to my choice, the Laravel framework, which intrigued me:
- its simplicity and less logical structure of the application,
- excellent architecture that could be customized to your needs,
- the presence of a heap of opportunities out of the box, which could help in the implementation of part of the portable functionality,
- comfortable console
- convenient tools for working with the database (migration, sitting),
- active, lively community
- Well, the most important thing is that the framework is actively developing, which, as I noted on my project, is very important.
For many people, April 1 is associated with the April Fool's Day, and for me, the birthday of a new project - KodiCMS on the laravel framework. On this day a new repository was created
https://github.com/KodiCMS/kodicms-laravel and the first commit was added to it.
I will tell you a little about the structure of the new CMS. Many people know that Laravel out of the box does not have a modular structure, and the packages are not the same as the modules, so the
ModuleLoader was the first thing to
write that helped with the organization of the modular structure and the dynamic connection of the modules simply by specifying its name in the config file.
As a result, the structure of the module has the following form
- config - application configs, can be overwritten from
/config/
folder- permissions.php - Used to specify a list of rights
- sitemap.php - Used to specify pages for the admin panel menu
- behaviors.php
- Console
- Commands - location of console command files
- database
- migrations - migration files that will be launched using the
cms:modules:migrate
command cms:modules:migrate
- seeds
- DatabaseSeeder.php - if exists, it will be launched by the command
cms:modules:seed
- Helpers - auxiliary module classes
- Http
- Controllers - module controllers
- Middleware
- routes.php - routes of the current module, wrapped in namespace
KodiCMS\{module}
- Observers - Observers for Eloquent models
- Providers
- ModuleServiceProvider.php - Service provider (inherited from
KodiCMS\CMS\Providers\ServiceProvider
), if any, will be launched at the time of application initialization
- resources
- js - javascript files, in this folder js files are searched by virtual paths
/backend/cms/js/{script.js}
- lang - Translation files for the module, available by the key of the module name in lower case
trans('{module}::file.key')
- views - Module templates, available by the key of the module name in the lower case
view('{module}::template')
- packages.php - In this file, you can connect your Assets (Media) packages
- Services - Service Containers
- ModuleContainer.php - If this file exists, it will be included as a system module file, which shows the relative paths and actions at the time of initialization. You must inherit from
KodiCMS\CMS\Loader\ModuleContainer
Read more about modularity
here.By analogy with the modules, it is planned to connect third-party plug-ins with the only difference that they will be activated via the administrative interface with the ability to download them from the repository.
As they say, the eyes are afraid, but the hands do. After the implementation of the modular structure, the procedure for transferring standard modules of the system and the implementation of basic capabilities began. And at the moment, according to my estimates, a little more than 60% of the functionality has been transferred:
Adding a modular structure to LaravelSystem core migrationTransferring the API moduleTransfer module "elFinder"Transferring the Pages moduleTransfer module "Layouts"Moving the module "Snippets"Email module transferMigrating the cron jobs moduleMoving the module "Widgets"Transferring the Dashboard ModuleMigrating the Users, Roles module- ACL module transfer
- Transfer module "Datasource"
- Transfer of the “Hyrid” plugin and its integration into the system with advanced functionality
- System Installer Implementation
- Implementing plug-in connection, with a structure similar to the modules
It was originally planned to transfer all the functionality for at least 6 months, but something went wrong and the process went faster ... The developers from the group in VK
http://vk.com/laravel_rus and on the
LaravelRUS channel became interested in the
system , after which enthusiasts began to offer assistance in developing the project of one of the coolest OpenSource CMS on one of the coolest frameworks.
Why do we need another CMS?
When using different CMS, I often come across the fact that many of them offer the same functionality but with slight differences. Those. in fact, many CMS pushes the user into a certain frame, be it the URL structure or the placement of content on the pages of the site. Many of them have a self-written core, which is either difficult to expand, or you have to study the documentation for a long time to start developing.
When writing my CMS, I wanted to collect all the best from them and combine them into one. For a start, I decided to use one of the popular frameworks and to make changes to the kernel at a minimum, so that any developer could enter the development process in the shortest possible time. In addition, I do not want a CMS like everyone else, just with my name, my goal is to create a certain constructor in which you can construct your own sections (blog, news, etc.) by adding fields of the necessary types to them through the admin panel, which not rigidly sewn into the system code, but would be added with the help of plug-ins by third-party developers. The same with content output on the site pages. So that each user without special knowledge in programming and picking site templates can display the necessary data, be it a list of documents or a menu of the site or plain HTML. Allow the content manager to use his favorite text editor, which can be embedded into the system through the API and fully used in the admin panels.
Ideas on the system of the sea and all of them are implemented and most of them have already been implemented. Some of them may need to be improved. But everything as usual rests on the developers. Therefore, we invite everyone to join the development, the more it will help to improve their experience in working with the Laravel framework, as well as to use their experience in the future.
As usual you can always see the result of the work:
Website:
http://laravel.kodicms.ru/backend- username : admin@site.com
- password : password
or
- username : test@test.com
- password : password
or download and install locally
https://github.com/KodiCMS/kodicms-laravelThanks
Thanks to KodiCMS, I discovered a world of good services and people who are ready to provide their help:
Ps In the near future, the first online meeting will be held to discuss the project, which will tell in more detail about the system, its history and current status
https://vk.com/kodicms?w=wall-48395169_287%2FallUpd. At the moment, the system still has the status of the Alpha version and there may be errors in work or deficiencies, which will be subsequently eliminated. Bug reports are welcome.