SO...
Today I found out this hook has been implemented and appears it will drop in 2.10. I gave it a test drive.
You'll be able to call a hook -- 'parseTemplate' -- that passes through the template object. Then you can access its $arrData and do what you wish:
Code:
public function parseMyTemplate($objTemplate)
{
$objTemplate->arrData['class'] = str_replace('mod_', 'module mod_', $objTemplate->arrData['class']);
return $objTemplate;
// Hooray! Now when I do my Greyboxes, I can style all of my modules the same,
// Without writing 50 selectors or digging into 50 templates. :)
// And if I want to change it later, it's just one line of code.
}
I'm super stoked about this. So may possibilities...
Bookmarks