Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

3
  • 1
    The D7 solution won't universally work, because $block['content'] might be a renderable array instead of a string of html. Also, this method will only render the content, without the '#theme' => 'block' wrapper. Commented Aug 9, 2018 at 11:33
  • The other D7 solution will cause a notice or sth, because drupal_render() has a by-reference parameter. Commented Aug 9, 2018 at 12:29
  • See drupal.org/project/drupal/issues/957038#comment-12723048 Commented Aug 9, 2018 at 12:29