You are here

function faq_ask_block_info in FAQ_Ask 7

Implements hook_block_info().

File

./faq_ask.module, line 1982
This module is an add-on to the FAQ module that allows users with the 'ask question' permission to create a question which will be queued for an 'expert' to answer.

Code

function faq_ask_block_info() {
  $block = array();
  $blocks['unanswered'] = array(
    'info' => t('Unanswered Questions'),
    'weight' => 0,
    'status' => 1,
    'region' => 'sidebar_first',
    'cache' => DRUPAL_CACHE_PER_ROLE,
  );
  $blocks['ask_a_question'] = array(
    'info' => t('Ask a Question'),
    'weight' => -1,
    // Set initially above the unanswered questions block
    'status' => 1,
    'region' => 'sidebar_first',
    'cache' => DRUPAL_CACHE_GLOBAL,
    'pages' => 'node/add/faq',
    // Do not initially show on the ask a question page
    'visibility' => BLOCK_VISIBILITY_NOTLISTED,
  );
  return $blocks;
}