Keeping MODX Relevant — Part Two

The Promise of and Struggle for Interoperability

I’ve watched the discussions and disagreements ebb and flow for years over interoperability in both the Open Source PHP CMS development communities, and later, the greater PHP development community. In the CMS communities it seemed like a pipe-dream, and there was rightfully some resistance from the developers involved with the various CMS products. What needed to happen before discussions about interoperability between offerings of a specific type of product were discussions about interoperability at a lower level. And I believe that was at least a partial motivation for the formation of the PHP-FIG.

The Benefits of PSR-3

Beyond the benefits of an autoloading standard, some of the additional PSRs that are coming out of the FIG are simply defining common interfaces that anyone can implement and share with anyone else that adopts the interface. The first of these was PSR-3, which defines a standard logging interface. Projects that use this interface can select from any number of implementations that implement the common logging interface. In fact, they can allow their users to simply configure and use a specific implementation through the use of a dependency injection container.

The Importance of the Proposed PSR-7

I don’t think I saw the true significance of what the FIG was achieving until I recently reviewed the PSR-7 specification. Though not yet accepted (it’s still in the proposal stage), I believe this set of proposed interfaces can do more to improve interoperability between PHP frameworks than any other standards recommendation adopted to date. What’s this proposal I’m so excited about and why is it important?

Extensibility and Interoperability via Middleware

A small scale example of what a standardized interface for HTTP messaging can accomplish can be seen in the existing Stack project. Stack provides a PHP implementation of middleware — an approach to extending an application by decorating it with a wrapper object which creates an outer layer around the existing application. This layer can alter the behavior of the application through the common interface, before and/or after the layer it wraps executes. Execution starts and finishes with the outmost Middleware layer.

Unit Tests and Agility

Making MODX more adaptable to the changing needs of web developers, designers, and content managers is what we are all after. I believe above all else, making MODX more testable, starting at the unit-testing level, will allow the MODX community to more quickly evolve and improve MODX features. By adopting these various standards and interfaces, and by utilizing existing libraries with complete test coverage, we don’t have to try to do everything ourselves. We can bring MODX up-to-date and start focusing on producing content management innovations instead of managing the complexity of home-grown solutions.


I’ve heard from numerous MODX developers over the past couple of years that think MODX should be rebuilt on top of the extremely popular Laravel framework. With Drupal 8 aligning with the Symfony framework, it might make sense to align the future of MODX with an existing solution and competitor. So I took it upon myself to explore Laravel.

Keeping Slim and Trim

It is clear to me that neither creating a new microframework from scratch, nor retrofitting test coverage on the existing legacy MODX codebase make any sense for the long-term viability of MODX. We do not want to continue the NIH culture that has already lead to some heavy technical debt. We want to instead immerse ourselves in existing, high-quality, stand-alone solutions that focus on doing what they do and doing it well, so that we can focus on doing Content Management well.

Crazy Ideas on Persistence

And if you think the struggle to find a new foundation on which to reconstruct a more relevant, next generation MODX core has been challenging, wait for Part Three. I’ll discuss how I see the role of database persistence changing in the next generation of MODX releases, and what tools might pave the way for those changes.



MODX Co-Founder and Chief Architect — loves cooking, backpacking, snowshoeing, playing drums, web development, Open Source Software, and photography

Love podcasts or audiobooks? Learn on the go with our new app.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Jason Coward

Jason Coward

MODX Co-Founder and Chief Architect — loves cooking, backpacking, snowshoeing, playing drums, web development, Open Source Software, and photography