When running DrupalWebTestCases we get a undefined index exception, because we don't use the footer region.
replacing if ( $page['footer']):
with if (isset ($page['footer']) && $page['footer']):
solves the problem for us.
Maybe you could adopt this.

Comments

Jeff Burnz’s picture

Category: bug » feature

Its possible, yes, I believe the bug is in Drupal core and one we tried to fix a couple of years ago. Think that the theme is just outputting a region here, nothing super special going on.

Typically the workaround is this:

<?php if ($footer = render($page['footer']))): ?>
  <?php print $footer; ?>
<?php endif; ?>

I can certainly add this to the theme, I have on other elements where access control is more critical (part of the issue as far as i can recall).

bechtold’s picture

I'm not sure if its a bug of Drupal core. If I don't use the footer, the $page['footer'] is not set.
So when Drupal tries to output the region, it tries to access an array index that is not existing.
I don't know much about the reder() function, but your suggested solution works as well.