Currently I've the following code:
$node = new stdClass;
$node->status = 1;
$node->uid = 1;
$node->type = 'advpoll_binary';
$node->title = t('Is this is test poll?');
$node->max_choices = 1; // Limits the total number of choices voters may select.
$node->show_votes = 1; // Users with the appropriate permissions will be able to see how each person voted.
$node->algorithm = 'plurality'; // Voting algorithm to use to calculate the winner.
$node->choice[1] = array('label' => 'Yes');
$node->choice[2] = array('label' => 'No');
$new_node = node_save($node);
The poll is created, the choices are accepted, but the rest of the settings are ignored.
[max_choices] => 0
[algorithm] =>
[show_votes] => 0
How do I apply these or other settings before creating creating the new node?
Comments
Comment #1
gobinathmD6 is EOL hence this issue won't be fixed (or) attended. So closing it.