Bonjour,
J'utilise XOOPS 2.0.9.2, je viens d'installer la version 1.1 de Xoopspoll, je n'arrive pas à mettre de sondages, lorsque j'en poste un et que je valide dans l'admin j'obtiens une page blanche
en Mode de mise au point :
Fatal error: Call to a member function on a non-object in /data/members/paid/a/i/aideordi.com/htdocs/www/modules/xoopspoll/admin/index.php on line 139
Voilà dans le fichier index.php les lignes de 138 à 175
if ( $op == "save" ) {
if (!$GLOBALS['xoopsSecurity']->check()) {
redirect_header('index.php', 3, implode('<br />', $GLOBALS['xoopsSecurity']->getErrors()));
}
$poll = new XoopsPoll();
$poll->setVar("question", $question);
$poll->setVar("description", $description);
if ( !empty($end_time) ) {
$poll->setVar("end_time", userTimeToServerTime(strtotime($end_time), $xoopsUser->timezone()));
} else {
// if expiration date is not set, set it to 10 days from now
$poll->setVar("end_time", time() + (86400 * 10));
}
$poll->setVar("display", $display);
$poll->setVar("weight", $weight);
$poll->setVar("multiple", $multiple);
if ( $notify == 1 ) {
// if notify, set mail status to "not mailed"
$poll->setVar("mail_status", POLL_NOTMAILED);
} else {
// if not notify, set mail status to already "mailed"
$poll->setVar("mail_status", POLL_MAILED);
}
$poll->setVar("user_id", $xoopsUser->getVar("uid"));
$new_poll_id = $poll->store();
if ( !empty($new_poll_id) ) {
$i = 0;
foreach ( $option_text as $optxt ) {
$optxt = trim($optxt);
if ( $optxt != "" ) {
$option = new XoopsPollOption();
$option->setVar("option_text", $optxt);
$option->setVar("option_color", $option_color[$i]);
$option->setVar("poll_id", $new_poll_id);
$option->store();
}
$i++;
}
(help