You are here

function demo_block in Demonstration site (Sandbox / Snapshot) 5

Implementation of hook_block().

File

./demo.module, line 93
Demonstration Site module

Code

function demo_block($op = 'list', $delta = 0, $edit = array()) {
  switch ($op) {
    case 'list':
      $blocks[0] = array(
        'info' => t('Demo site reset'),
        'enabled' => 1,
        'region' => 'right',
      );
      return $blocks;
    case 'view':
      $block = array(
        'subject' => t('Reset demo'),
        'content' => drupal_get_form('demo_reset_now'),
      );
      return $block;
  }
}