You are here

function advpoll_results_page in Advanced Poll 7.3

Same name and namespace in other branches
  1. 6.3 advpoll.pages.inc \advpoll_results_page()
  2. 6 advpoll.pages.inc \advpoll_results_page()
  3. 6.2 advpoll.pages.inc \advpoll_results_page()
  4. 7 includes/advpoll.pages.inc \advpoll_results_page()
  5. 7.2 includes/advpoll.pages.inc \advpoll_results_page()

Display the poll's results for users with appropriate permissions.

Parameters

$node: An advpoll node.

Return value

string

1 string reference to 'advpoll_results_page'
advpoll_menu in ./advpoll.module
Implements hook_menu().

File

includes/advpoll.pages.inc, line 720
Advanced Poll Pages Include.

Code

function advpoll_results_page($node) {
  drupal_add_css(drupal_get_path('module', 'advpoll') . '/css/advpoll.css', array(
    'group' => CSS_DEFAULT,
    'every_page' => TRUE,
  ));
  $data = advpoll_get_data($node);
  $output = '';
  if ($node) {
    $output = advpoll_display_results($node->nid, $data, 1);
  }
  return $output;
}