function block_block_view

Implements hook_block_view().

Generates the administrator-defined blocks for display.

1 call to block_block_view()
BlockTest::testCustomBlock in drupal/core/modules/block/lib/Drupal/block/Tests/BlockTest.php
Test creating custom block, moving it to a specific region and then deleting it.

File

drupal/core/modules/block/block.module, line 254
Controls the visual building blocks a page is constructed with.

Code

function block_block_view($delta = '') {
  $block = db_query('SELECT body, format FROM {block_custom} WHERE bid = :bid', array(
    ':bid' => $delta,
  ))
    ->fetchObject();
  $data['subject'] = NULL;
  $data['content'] = check_markup($block->body, $block->format, '', TRUE);
  return $data;
}