Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Add a hook to add module generated output to the error page.
In our case we have to add a search box to the page after the content. Usually this could be done by adding a page--customerror.tpl.php, but in our case this did not work - possibly as we are using layouts.
Comment | File | Size | Author |
---|---|---|---|
#2 | 2652938-2.patch | 365 bytes | John Cook |
Comments
Comment #2
John Cook CreditAttribution: John Cook at Curve Agency commentedI've added a single line to the
customerror_page()
function to call the hook:drupal_alter('customerror_post_render', $output);
Then in a custom module I can do:
Comment #3
gisleNo review for nearly eight years. Closing as outdated.