poll_teaser

Definition

poll_teaser($node)
modules/poll/poll.module, line 354

Description

Creates a simple teaser that lists all the choices.

Code

<?php
function poll_teaser($node) {
  $teaser = NULL;
  if (is_array($node->choice)) {
    foreach ($node->choice as $k => $choice) {
      if ($choice['chtext'] != '') {
        $teaser .= '* '. check_plain($choice['chtext']) ."\n";
      }
    }
  }
  return $teaser;
}
?>
 
 

Drupal is a registered trademark of Dries Buytaert.