Drupal Page Builder Framework: A Review

Thu, 19/01/2017 - 09:59

Drupal provides multiple tools to make content management easy for the layman. By providing image styles and custom field types to content, anyone can upload and modify their web pages without knowing any, or maybe a little bit of HTML (HyperText Markup Language).

The real challenge in providing a CMS (Content Management System) would be balancing the security/safety of fixed fields displaying specific values in a specific order, with the flexibility in layout and formatting some knowledge of HTML could provide.

More often than not, WYSIWYG (What You See Is What You Get) input fields address most common layout and formatting needs, but not always without sacrificing the security gained from filtering out potentially harmful markup or requiring a higher level of HTML knowledge from your clients.

For content managers

All content managers really want is the ability to add rich media in between paragraphs of copy. While this seems simple enough to achieve with WYSIWYG, it often neglects to provide properties to the content that can respond to a different theme or display. Not to mention making sure all media assets are managed and catalogued by the CMS so this content can be re-used (and sometimes reformatted) on other areas of the website while remaining accessible to search engines, screen-readers and other non-traditional audiences.

The page builder framework module addresses this problem by separating media types into their own entity and allows content managers to add as many of these entities to content as they like. Each of these entities, called "tiers", are configured individually, allowing the heavy lifting of displaying and markup to be handed back to the CMS while providing the freedom of order and flow back to the content manager. For example, you can arbitrarily add a video row (a.k.a "tier") after a formatted paragraph, then another paragraph, followed by an image with a caption, etc.

Forthemers and site builders

The page builder framework provides custom tier entities with their own unique view modes. That means, themers can take the complex markup back into the tier templates while keeping the node templates as clean and simple as possible without having to worry too much about user-generated content and the risks associated with those.

Site builders can create as many tier types as they can imagine, with the opportunity of managing which types are available to nodes on a bundle level. For example, product nodes could have video tiers, while gallery nodes could have image-reference tiers.

Tiers are fieldable, like any entity on Drupal, so constructing rich content works and displays in the same way nodes do and should be familiar to any novice.

For developers

Using Drupal's block engine, developers can create and cater for more interactive needs of a website. While modules like Context provide powerful means of placing "widgets" onto a page, it remains difficult to hand complex layout tasks to most content managers. By using the entity API's view and preprocess hooks, widgets can be extended to display information not generally associated with normal content.

This kind of entity manipulation makes it possible for content managers to design their own single page application websites, or landing pages fetching content from a variety of places on the site, for example placing a competition entry form between other featured content reference rows.

The possibilities are truly endless. Look into Rogerwilco's Drupal development offerings for your site or see how we can assist with your Drupal 9 upgrade.

Need Assistance with Digital Strategy?

Rogerwilco’s team of strategists, business analysts and data scientists is here to help.