function messaging_template_pre_render_element in Messaging 7
Prepare element (add format, method properties recursively)
2 calls to messaging_template_pre_render_element()
- messaging_template_pre_render_body in messaging_template/
messaging_template.module - Prepare body elements
- messaging_template_pre_render_text in messaging_template/
messaging_template.module - Prepare text
File
- messaging_template/
messaging_template.module, line 117 - Messaging Template Drupal Messaging Framework
Code
function messaging_template_pre_render_element($element) {
// Add properties to all the tree
$properties = array(
'#format' => $element['#format'],
'#method' => $element['#method'],
);
foreach (element_children($element) as $index) {
$element[$index] = $properties + $element[$index];
$element[$index] = messaging_template_pre_render_element($element[$index]);
}
return $element;
}