function hook_feedback_view_alter in Feedback 7.2
The feedback entry was built; the module may modify the structured content.
This hook is called after the content has been assembled in a structured array and may be used for doing processing which requires that the complete content structure has been built.
Parameters
$build: A renderable array representing the feedback entry.
See also
1 invocation of hook_feedback_view_alter()
- feedback_view in ./
feedback.admin.inc - Generate a render array for viewing a feedback entry.
File
- ./
feedback.api.php, line 120 - Hooks provided by the Feedback module.
Code
function hook_feedback_view_alter(&$build) {
// Check for the existence of a field added by another module.
if (isset($build['an_additional_field'])) {
// Change its weight.
$build['an_additional_field']['#weight'] = -10;
}
// Add a #post_render callback to act on the rendered HTML of the entry.
$build['#post_render'][] = 'my_module_feedback_post_render';
}