// By default, expiration date is 6 months after last day
$_SESSION['form']->end_date=$max_expiry_time;
$form->end_date=$max_expiry_time;
}
// Insert poll in database
$ids=$pollService->createPoll($_SESSION['form']);
$ids=$pollService->createPoll($form);
$poll_id=$ids[0];
$admin_poll_id=$ids[1];
...
...
@@ -92,15 +98,15 @@ if (empty($_SESSION['form']->title) || empty($_SESSION['form']->admin_name) || (
if($config['use_smtp']===true){
$message=__('Mail',"This is the message you have to send to the people you want to poll. \nNow, you have to send this message to everyone you want to poll.");
$message.='<br/><br/>';
$message.=Utils::htmlMailEscape($_SESSION['form']->admin_name).' '.__('Mail','hast just created a poll called').' : "'.Utils::htmlMailEscape($_SESSION['form']->title).'".<br/>';
$message.=Utils::htmlMailEscape($form->admin_name).' '.__('Mail','hast just created a poll called').' : "'.Utils::htmlMailEscape($form->title).'".<br/>';
$message.=sprintf(__('Mail','Thanks for filling the poll at the link above').' :<br/><br/><a href="%1$s">%1$s</a>',Utils::getUrlSondage($poll_id));
$message_admin=__('Mail',"This message should NOT be sent to the polled people. It is private for the poll's creator.\n\nYou can now modify it at the link above");
$mailService->send($_SESSION['form']->admin_mail,'['.NOMAPPLICATION.']['.__('Mail','For sending to the polled users').'] '.__('Generic','Poll').': '.$_SESSION['form']->title,$message);
$mailService->send($form->admin_mail,'['.NOMAPPLICATION.']['.__('Mail','For sending to the polled users').'] '.__('Generic','Poll').': '.$form->title,$message);
}
}
...
...
@@ -112,7 +118,7 @@ if (empty($_SESSION['form']->title) || empty($_SESSION['form']->admin_name) || (
// By default, expiration date is 6 months after last day
$_SESSION['form']->end_date=$max_expiry_time;
$form->end_date=$max_expiry_time;
}
// Insert poll in database
$ids=$pollService->createPoll($_SESSION['form']);
$ids=$pollService->createPoll($form);
$poll_id=$ids[0];
$admin_poll_id=$ids[1];
...
...
@@ -213,7 +224,7 @@ switch ($step) {
if($config['use_smtp']===true){
$message=__('Mail',"This is the message you have to send to the people you want to poll. \nNow, you have to send this message to everyone you want to poll.");
$message.='<br/><br/>';
$message.=Utils::htmlEscape($_SESSION['form']->admin_name).' '.__('Mail','hast just created a poll called').' : "'.Utils::htmlEscape($_SESSION['form']->title).'".<br/>';
$message.=Utils::htmlEscape($form->admin_name).' '.__('Mail','hast just created a poll called').' : "'.Utils::htmlEscape($form->title).'".<br/>';
$message.=__('Mail','Thanks for filling the poll at the link above').' :<br/><br/><a href="%1$s">%1$s</a>';
$message_admin=__('Mail',"This message should NOT be sent to the polled people. It is private for the poll's creator.\n\nYou can now modify it at the link above");
$mailService->send($_SESSION['form']->admin_mail,'['.NOMAPPLICATION.']['.__('Mail','For sending to the polled users').'] '.__('Generic','Poll').': '.Utils::htmlEscape($_SESSION['form']->title),$message);
$mailService->send($form->admin_mail,'['.NOMAPPLICATION.']['.__('Mail','For sending to the polled users').'] '.__('Generic','Poll').': '.Utils::htmlEscape($form->title),$message);