Merge pull request #18904 from cfoellmann/PR/hook-beforebodyclose

NEW add hook `beforeBodyClose`
This commit is contained in:
Laurent Destailleur 2021-10-05 16:52:46 +02:00 committed by GitHub
commit 30ac1fbf01
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -3081,7 +3081,7 @@ if (!function_exists("llxFooter")) {
*/
function llxFooter($comment = '', $zone = 'private', $disabledoutputofmessages = 0)
{
global $conf, $db, $langs, $user, $mysoc, $object;
global $conf, $db, $langs, $user, $mysoc, $object, $hookmanager;
global $delayedhtmlcontent;
global $contextpage, $page, $limit;
global $dolibarr_distrib;
@ -3304,6 +3304,11 @@ if (!function_exists("llxFooter")) {
}
}
$reshook = $hookmanager->executeHooks('beforeBodyClose'); // Note that $action and $object may have been modified by some hooks
if ($reshook > 0) {
print $hookmanager->resPrint;
}
print "</body>\n";
print "</html>\n";
}