3.4.7. output_templates

This hook can be used to alter the list of templates that will be displayed by the phorum_api_output() call.

Call time:

After sending the page header template, but before sending the main page content.

Hook input:

An array, containing the names of the templates to display in the page body (between the header and footer template).

Hook output:

Same as input, possibly modified.

Example code:

function phorum_mod_foo_output_templates($templates)
{
    // Add some advertisements at the top and bottom of the page.
    array_unshift($templates, "foo::top_advertisement);
    array_push($templates, "foo::bottom_advertisement);

    return $templates;
}