Page Tree Traversal

Permalink
I’ve recently worked on three separate projects that required some extended functionality on top of Concrete5′s core Collection Attribute functionality.

This initially started off with just a little logic added to the view for the particular page type, however this became messy as more functionality was required around it across the three separate projects.

From these requirements I built a view helper designed to easily access Attributes and Areas (that contain blocks) from a page’s ancestors, traversing up the page tree until it finds something with a value (or in teh case of Areas that contain blocks).

Documentation and the helper itself are posted on my blog at

http://jaredquinn.info/2011/02/concrete5-page-tree-traversal-helper...

Jared

jaredquinn