November 17, 2009
A few weeks ago I wrote about how to use the layout management features of HomePortals on a ColdBox 3 application. This time I want to show how to do the same but with an application built with the Model-Glue framework and also explain a bit more of why would you want to do so in the first place.
On top of that, HomePortals can manage libraries of user-defined resources without being tied to a relational database. Resources can be anything that your application requires, such as blocks of content, images, products, blog entries, etc.
These two features makes HomePortals a good way for rapidly adding "Content Management" features to any existing application. And the beauty is that your application will only interact with HomePortals on a purely programmatic way, like you maybe already do with ColdSpring or Transfer.
The sample application shows how a Model-Glue application can integrate and render HomePortals pages. It shows how to take advantage of features such as pre-defined widgets (RSSReader, image), use of resource libraries for content blocks, and more important how to encapsulate regular Model-Glue events as modular content on the page.
I think the last item is very crucial for integrating with existing applications. By embedding regular events, you can use any predefined features in HomePortals as ancillary content that is already built (think static content resources, common widgets) but still have the main logic built as regular elements of the framework. And you are not restricted to do only one event per page, but you can mix multiple events on the same page as if they were independent of each other.
To download the sample application you can go here.
Here are some aspects worth mentioning:
I am currently working on an integration with MachII but still have some issues to solve there. After that I'd like to explore FW/1 and the venerable FuseBox.
PS: By the way, doing integration work is a great way of learning the "guts" of a framework. Highly recommend it :)