posted by Sean Middleditch on March 31st, 2010 - 12:49pm PDT
A new release of Sugar is out! This version sports several critical new features, including layout templates and function escaping control.
First and foremost is support for layout templates and sections. A layout template allows nested templates, where one master template controls the overall site layout and framework while the child template handles the content of a specific page.
The layout feature is coupled with a new mechanism for sections and inserts. A section is a block of template code denoted with a unique name that can then be overridden by a child template. This allows the master layout template to include more than one section of content that the child can replace, such as allowing a child to set the title, navigation menu, and main content area of the layout with a single file and no additional PHP code.
Finally, function plugins can now be defined to disable automatic HTML escaping of the results on a per-function basis. This is highly useful for functions whose purpose is to generate HTML output, such as bbcode processing functions or similar routines.
As always, checkout the NEWS and README files for additional details.