Active
Project:
Printer, email and PDF versions
Version:
7.x-2.x-dev
Component:
Code
Priority:
Major
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
6 Mar 2015 at 07:40 UTC
Updated:
6 Mar 2015 at 07:40 UTC
Line 261 of print.pages.inc calls block_get_blocks_by_region() but I work on many sites that don't ever have the block module on because they only use panels for layout.
<?php
switch (variable_get('print_footer_options', PRINT_FOOTER_OPTIONS_DEFAULT)) {
case 1: // theme's
$footer_blocks = block_get_blocks_by_region('footer');
$footer = variable_get('site_footer', FALSE) . "\n" . drupal_render($footer_blocks);
break;
case 2: // user-specifed
$footer = variable_get('print_footer_user', PRINT_FOOTER_USER_DEFAULT);
break;
}
?>
This patch changes case 1 to the following
<?php
$footer = variable_get('site_footer', FALSE);
if (module_exists('block')) {
$footer_blocks = block_get_blocks_by_region('footer');
$footer .= "\n" . drupal_render($footer_blocks);
}
?>
| Comment | File | Size | Author |
|---|---|---|---|
| print-check-block-module.patch | 784 bytes | sonictruth |