You are here

function advpoll_node_info in Advanced Poll 5

Same name and namespace in other branches
  1. 6.3 advpoll.module \advpoll_node_info()
  2. 6 advpoll.module \advpoll_node_info()
  3. 6.2 advpoll.module \advpoll_node_info()

Implementation of hook_node_info().

File

./advpoll.module, line 57
Advanced Poll - a sophisticated polling module for voting, elections, and group decision-making.

Code

function advpoll_node_info() {
  $modes = _advpoll_list_modes();
  $info = array();
  foreach ($modes as $mode) {
    $info['advpoll_' . $mode['name']] = array(
      'name' => t('@name poll', array(
        '@name' => $mode['name_label'],
      )),
      'module' => 'advpoll',
      'description' => $mode['description'],
      'title_label' => t('@name question', array(
        '@name' => $mode['name_label'],
      )),
      'body_label' => t('Description'),
    );
  }
  return $info;
}