Hello, I'd like to modify the theme_advpoll_block_mostrecent() to do the following: I need to hide the body content of the poll and display only the title and choices (of course with possibility to vote in the block).
I know, I have to replace the line 57 in advpoll.module:
$output .= drupal_render($node->content);
But I don't know what to write instead. Any ideas?

Comments

anders.fajerson’s picture

Status: Active » Fixed

You can put unset($node->content['body']); just before $output .= drupal_render($node->content);

Anonymous’s picture

Status: Fixed » Closed (fixed)
WeRockYourWeb.com’s picture

Version: 5.x-1.0-beta4 » 6.x-3.x-dev

How would this work in Drupal 6? I've got:

/* theme adv poll block */
function secure_advpoll_block_mostrecent() {
unset($node->content['body']);
$output .= drupal_render($node->content);
}

In my template.php file, but that doesn't seem to work.