Replace calls to __('Section\Key') with __('Section', 'Key')

This commit is contained in:
Olivier PEREZ 2015-03-30 15:19:56 +02:00
parent da2cdeda12
commit 6d34631fbf
33 changed files with 353 additions and 341 deletions

View File

@ -26,6 +26,6 @@ $content = ob_get_clean();
$smarty->assign('title', _('Administration')); $smarty->assign('title', _('Administration'));
$smarty->assign('logs', $content); $smarty->assign('logs', $content);
$smarty->assign('title', __('Admin\\Logs')); $smarty->assign('title', __('Admin', 'Logs'));
$smarty->display('admin/logs.tpl'); $smarty->display('admin/logs.tpl');

View File

@ -102,6 +102,6 @@ $smarty->assign('countSkipped', $countSkipped);
$smarty->assign('countTotal', $countTotal); $smarty->assign('countTotal', $countTotal);
$smarty->assign('time', $total_time = round((microtime(true)-$_SERVER['REQUEST_TIME_FLOAT']), 4)); $smarty->assign('time', $total_time = round((microtime(true)-$_SERVER['REQUEST_TIME_FLOAT']), 4));
$smarty->assign('title', __('Admin\\Migration')); $smarty->assign('title', __('Admin', 'Migration'));
$smarty->display('admin/migration.tpl'); $smarty->display('admin/migration.tpl');

View File

@ -95,6 +95,6 @@ $smarty->assign('crsf', $securityService->getToken('admin'));
$smarty->assign('search', $search); $smarty->assign('search', $search);
$smarty->assign('search_query', buildSearchQuery($search)); $smarty->assign('search_query', buildSearchQuery($search));
$smarty->assign('title', __('Admin\\Polls')); $smarty->assign('title', __('Admin', 'Polls'));
$smarty->display('admin/polls.tpl'); $smarty->display('admin/polls.tpl');

View File

@ -53,6 +53,6 @@ if ($action === 'purge' && $securityService->checkCsrf('admin', $_POST['csrf']))
$smarty->assign('message', $message); $smarty->assign('message', $message);
$smarty->assign('crsf', $securityService->getToken('admin')); $smarty->assign('crsf', $securityService->getToken('admin'));
$smarty->assign('title', __('Admin\\Purge')); $smarty->assign('title', __('Admin', 'Purge'));
$smarty->display('admin/purge.tpl'); $smarty->display('admin/purge.tpl');

View File

@ -52,7 +52,7 @@ if (!empty($_GET['poll']) && strlen($_GET['poll']) === 24) {
} }
if (!$poll) { if (!$poll) {
$smarty->assign('error', __('Error\\This poll doesn\'t exist !')); $smarty->assign('error', __('Error', 'This poll doesn\'t exist !'));
$smarty->display('error.tpl'); $smarty->display('error.tpl');
exit; exit;
} }
@ -120,9 +120,9 @@ if (isset($_POST['update_poll_info'])) {
// Update poll in database // Update poll in database
if ($updated && $adminPollService->updatePoll($poll)) { if ($updated && $adminPollService->updatePoll($poll)) {
$message = new Message('success', __('adminstuds\\Poll saved')); $message = new Message('success', __('adminstuds', 'Poll saved'));
} else { } else {
$message = new Message('danger', __('Error\\Failed to save poll')); $message = new Message('danger', __('Error', 'Failed to save poll'));
$poll = $pollService->findById($poll_id); $poll = $pollService->findById($poll_id);
} }
} }
@ -145,19 +145,19 @@ if (!empty($_POST['save'])) { // Save edition of an old vote
$choices = $inputService->filterArray($_POST['choices'], FILTER_VALIDATE_REGEXP, ['options' => ['regexp' => CHOICE_REGEX]]); $choices = $inputService->filterArray($_POST['choices'], FILTER_VALIDATE_REGEXP, ['options' => ['regexp' => CHOICE_REGEX]]);
if (empty($editedVote)) { if (empty($editedVote)) {
$message = new Message('danger', __('Error\\Something is going wrong...')); $message = new Message('danger', __('Error', 'Something is going wrong...'));
} }
if (count($choices) != count($_POST['choices'])) { if (count($choices) != count($_POST['choices'])) {
$message = new Message('danger', __('Error\\There is a problem with your choices')); $message = new Message('danger', __('Error', 'There is a problem with your choices'));
} }
if ($message == null) { if ($message == null) {
// Update vote // Update vote
$result = $pollService->updateVote($poll_id, $editedVote, $name, $choices); $result = $pollService->updateVote($poll_id, $editedVote, $name, $choices);
if ($result) { if ($result) {
$message = new Message('success', __('adminstuds\\Vote updated')); $message = new Message('success', __('adminstuds', 'Vote updated'));
} else { } else {
$message = new Message('danger', __('Error\\Update vote failed')); $message = new Message('danger', __('Error', 'Update vote failed'));
} }
} }
} elseif (isset($_POST['save'])) { // Add a new vote } elseif (isset($_POST['save'])) { // Add a new vote
@ -165,19 +165,19 @@ if (!empty($_POST['save'])) { // Save edition of an old vote
$choices = $inputService->filterArray($_POST['choices'], FILTER_VALIDATE_REGEXP, ['options' => ['regexp' => CHOICE_REGEX]]); $choices = $inputService->filterArray($_POST['choices'], FILTER_VALIDATE_REGEXP, ['options' => ['regexp' => CHOICE_REGEX]]);
if (empty($name)) { if (empty($name)) {
$message = new Message('danger', __('Error\\The name is invalid')); $message = new Message('danger', __('Error', 'The name is invalid'));
} }
if (count($choices) != count($_POST['choices'])) { if (count($choices) != count($_POST['choices'])) {
$message = new Message('danger', __('Error\\There is a problem with your choices')); $message = new Message('danger', __('Error', 'There is a problem with your choices'));
} }
if ($message == null) { if ($message == null) {
// Add vote // Add vote
$result = $pollService->addVote($poll_id, $name, $choices); $result = $pollService->addVote($poll_id, $name, $choices);
if ($result) { if ($result) {
$message = new Message('success', __('adminstuds\\Vote added')); $message = new Message('success', __('adminstuds', 'Vote added'));
} else { } else {
$message = new Message('danger', __('Error\\Adding vote failed')); $message = new Message('danger', __('Error', 'Adding vote failed'));
} }
} }
} }
@ -189,9 +189,9 @@ if (!empty($_POST['save'])) { // Save edition of an old vote
if (!empty($_POST['delete_vote'])) { if (!empty($_POST['delete_vote'])) {
$vote_id = filter_input(INPUT_POST, 'delete_vote', FILTER_VALIDATE_INT); $vote_id = filter_input(INPUT_POST, 'delete_vote', FILTER_VALIDATE_INT);
if ($adminPollService->deleteVote($poll_id, $vote_id)) { if ($adminPollService->deleteVote($poll_id, $vote_id)) {
$message = new Message('success', __('adminstuds\\Vote deleted')); $message = new Message('success', __('adminstuds', 'Vote deleted'));
} else { } else {
$message = new Message('danger', __('Error\\Failed to delete the vote')); $message = new Message('danger', __('Error', 'Failed to delete the vote'));
} }
} }
@ -202,15 +202,15 @@ if (!empty($_POST['delete_vote'])) {
if (isset($_POST['remove_all_votes'])) { if (isset($_POST['remove_all_votes'])) {
$smarty->assign('poll_id', $poll_id); $smarty->assign('poll_id', $poll_id);
$smarty->assign('admin_poll_id', $admin_poll_id); $smarty->assign('admin_poll_id', $admin_poll_id);
$smarty->assign('title', __('Generic\\Poll') . ' - ' . $poll->title); $smarty->assign('title', __('Generic', 'Poll') . ' - ' . $poll->title);
$smarty->display('confirm/delete_votes.tpl'); $smarty->display('confirm/delete_votes.tpl');
exit; exit;
} }
if (isset($_POST['confirm_remove_all_votes'])) { if (isset($_POST['confirm_remove_all_votes'])) {
if ($adminPollService->cleanVotes($poll_id)) { if ($adminPollService->cleanVotes($poll_id)) {
$message = new Message('success', __('adminstuds\\All votes deleted')); $message = new Message('success', __('adminstuds', 'All votes deleted'));
} else { } else {
$message = new Message('danger', __('Error\\Failed to delete all votes')); $message = new Message('danger', __('Error', 'Failed to delete all votes'));
} }
} }
@ -223,16 +223,16 @@ if (isset($_POST['add_comment'])) {
$comment = strip_tags($_POST['comment']); $comment = strip_tags($_POST['comment']);
if (empty($name)) { if (empty($name)) {
$message = new Message('danger', __('Error\\The name is invalid')); $message = new Message('danger', __('Error', 'The name is invalid'));
} }
if ($message == null) { if ($message == null) {
// Add comment // Add comment
$result = $pollService->addComment($poll_id, $name, $comment); $result = $pollService->addComment($poll_id, $name, $comment);
if ($result) { if ($result) {
$message = new Message('success', __('Comments\\Comment added')); $message = new Message('success', __('Comments', 'Comment added'));
} else { } else {
$message = new Message('danger', __('Error\\Comment failed')); $message = new Message('danger', __('Error', 'Comment failed'));
} }
} }
@ -246,9 +246,9 @@ if (!empty($_POST['delete_comment'])) {
$comment_id = filter_input(INPUT_POST, 'delete_comment', FILTER_VALIDATE_INT); $comment_id = filter_input(INPUT_POST, 'delete_comment', FILTER_VALIDATE_INT);
if ($adminPollService->deleteComment($poll_id, $comment_id)) { if ($adminPollService->deleteComment($poll_id, $comment_id)) {
$message = new Message('success', __('adminstuds\\Comment deleted')); $message = new Message('success', __('adminstuds', 'Comment deleted'));
} else { } else {
$message = new Message('danger', __('Error\\Failed to delete the comment')); $message = new Message('danger', __('Error', 'Failed to delete the comment'));
} }
} }
@ -259,15 +259,15 @@ if (!empty($_POST['delete_comment'])) {
if (isset($_POST['remove_all_comments'])) { if (isset($_POST['remove_all_comments'])) {
$smarty->assign('poll_id', $poll_id); $smarty->assign('poll_id', $poll_id);
$smarty->assign('admin_poll_id', $admin_poll_id); $smarty->assign('admin_poll_id', $admin_poll_id);
$smarty->assign('title', __('Generic\\Poll') . ' - ' . $poll->title); $smarty->assign('title', __('Generic', 'Poll') . ' - ' . $poll->title);
$smarty->display('confirm/delete_comments.tpl'); $smarty->display('confirm/delete_comments.tpl');
exit; exit;
} }
if (isset($_POST['confirm_remove_all_comments'])) { if (isset($_POST['confirm_remove_all_comments'])) {
if ($adminPollService->cleanComments($poll_id)) { if ($adminPollService->cleanComments($poll_id)) {
$message = new Message('success', __('All comments deleted')); $message = new Message('success', __('adminstuds', 'All comments deleted'));
} else { } else {
$message = new Message('danger', __('Error\\Failed to delete all comments')); $message = new Message('danger', __('Error', 'Failed to delete all comments'));
} }
} }
@ -278,19 +278,19 @@ if (isset($_POST['confirm_remove_all_comments'])) {
if (isset($_POST['delete_poll'])) { if (isset($_POST['delete_poll'])) {
$smarty->assign('poll_id', $poll_id); $smarty->assign('poll_id', $poll_id);
$smarty->assign('admin_poll_id', $admin_poll_id); $smarty->assign('admin_poll_id', $admin_poll_id);
$smarty->assign('title', __('Generic\\Poll') . ' - ' . $poll->title); $smarty->assign('title', __('Generic', 'Poll') . ' - ' . $poll->title);
$smarty->display('confirm/delete_poll.tpl'); $smarty->display('confirm/delete_poll.tpl');
exit; exit;
} }
if (isset($_POST['confirm_delete_poll'])) { if (isset($_POST['confirm_delete_poll'])) {
if ($adminPollService->deleteEntirePoll($poll_id)) { if ($adminPollService->deleteEntirePoll($poll_id)) {
$message = new Message('success', __('Generic\\Poll fully deleted')); $message = new Message('success', __('adminstuds', 'Poll fully deleted'));
} else { } else {
$message = new Message('danger', __('Error\\Failed to delete the poll')); $message = new Message('danger', __('Error', 'Failed to delete the poll'));
} }
$smarty->assign('poll_id', $poll_id); $smarty->assign('poll_id', $poll_id);
$smarty->assign('admin_poll_id', $admin_poll_id); $smarty->assign('admin_poll_id', $admin_poll_id);
$smarty->assign('title', __('Generic\\Poll') . ' - ' . $poll->title); $smarty->assign('title', __('Generic', 'Poll') . ' - ' . $poll->title);
$smarty->assign('message', $message); $smarty->assign('message', $message);
$smarty->display('poll_deleted.tpl'); $smarty->display('poll_deleted.tpl');
exit; exit;
@ -316,9 +316,9 @@ if (!empty($_POST['delete_column'])) {
} }
if ($result) { if ($result) {
$message = new Message('success', __('Column deleted')); $message = new Message('success', __('adminstuds', 'Column deleted'));
} else { } else {
$message = new Message('danger', __('Error\\Failed to delete the column')); $message = new Message('danger', __('Error', 'Failed to delete the column'));
} }
} }
@ -330,7 +330,7 @@ if (isset($_POST['add_slot'])) {
$smarty->assign('poll_id', $poll_id); $smarty->assign('poll_id', $poll_id);
$smarty->assign('admin_poll_id', $admin_poll_id); $smarty->assign('admin_poll_id', $admin_poll_id);
$smarty->assign('format', $poll->format); $smarty->assign('format', $poll->format);
$smarty->assign('title', __('Generic\\Poll') . ' - ' . $poll->title); $smarty->assign('title', __('Generic', 'Poll') . ' - ' . $poll->title);
$smarty->display('add_slot.tpl'); $smarty->display('add_slot.tpl');
exit; exit;
} }
@ -347,9 +347,9 @@ if (isset($_POST['confirm_add_slot'])) {
} }
if ($result) { if ($result) {
$message = new Message('success', __('adminstuds\\Choice added')); $message = new Message('success', __('adminstuds', 'Choice added'));
} else { } else {
$message = new Message('danger', __('Error\\Failed to add the column')); $message = new Message('danger', __('Error', 'Failed to add the column'));
} }
} }
@ -363,7 +363,7 @@ $comments = $pollService->allCommentsByPollId($poll_id);
$smarty->assign('poll_id', $poll_id); $smarty->assign('poll_id', $poll_id);
$smarty->assign('admin_poll_id', $admin_poll_id); $smarty->assign('admin_poll_id', $admin_poll_id);
$smarty->assign('poll', $poll); $smarty->assign('poll', $poll);
$smarty->assign('title', __('Generic\\Poll') . ' - ' . $poll->title); $smarty->assign('title', __('Generic', 'Poll') . ' - ' . $poll->title);
$smarty->assign('expired', strtotime($poll->end_date) < time()); $smarty->assign('expired', strtotime($poll->end_date) < time());
$smarty->assign('deletion_date', $poll->end_date + PURGE_DELAY * 86400); $smarty->assign('deletion_date', $poll->end_date + PURGE_DELAY * 86400);
$smarty->assign('slots', $poll->format === 'D' ? $pollService->splitSlots($slots) : $slots); $smarty->assign('slots', $poll->format === 'D' ? $pollService->splitSlots($slots) : $slots);

View File

@ -39,11 +39,11 @@ if (isset($_POST['lang']) && is_string($_POST['lang']) && in_array($_POST['lang'
$html_lang = substr($locale, 0, 2); $html_lang = substr($locale, 0, 2);
/* Date Format */ /* Date Format */
$date_format['txt_full'] = __('Date\\FULL'); //summary in create_date_poll.php and removal date in choix_(date|autre).php $date_format['txt_full'] = __('Date', 'FULL'); //summary in create_date_poll.php and removal date in choix_(date|autre).php
$date_format['txt_short'] = __('Date\\SHORT'); // radio title $date_format['txt_short'] = __('Date', 'SHORT'); // radio title
$date_format['txt_day'] = __('Date\\DAY'); $date_format['txt_day'] = __('Date', 'DAY');
$date_format['txt_date'] = __('Date\\DATE'); $date_format['txt_date'] = __('Date', 'DATE');
$date_format['txt_month_year'] = __('Date\\MONTH_YEAR'); $date_format['txt_month_year'] = __('Date', 'MONTH_YEAR');
if (strtoupper(substr(PHP_OS, 0, 3)) == 'WIN') { //%e can't be used on Windows platform, use %#d instead if (strtoupper(substr(PHP_OS, 0, 3)) == 'WIN') { //%e can't be used on Windows platform, use %#d instead
foreach ($date_format as $k => $v) { foreach ($date_format as $k => $v) {
$date_format[$k] = preg_replace('#(?<!%)((?:%%)*)%e#', '\1%#d', $v); //replace %e by %#d for windows $date_format[$k] = preg_replace('#(?<!%)((?:%%)*)%e#', '\1%#d', $v); //replace %e by %#d for windows

View File

@ -30,15 +30,15 @@ function bandeau_titre($titre)
if(count($ALLOWED_LANGUAGES) > 1){ if(count($ALLOWED_LANGUAGES) > 1){
echo '<form method="post" action="" class="hidden-print"> echo '<form method="post" action="" class="hidden-print">
<div class="input-group input-group-sm pull-right col-md-2 col-xs-4"> <div class="input-group input-group-sm pull-right col-md-2 col-xs-4">
<select name="lang" class="form-control" title="'. __('Language selector\\Select the language') .'" >' . liste_lang() . '</select> <select name="lang" class="form-control" title="'. __('Language selector', 'Select the language') .'" >' . liste_lang() . '</select>
<span class="input-group-btn"> <span class="input-group-btn">
<button type="submit" class="btn btn-default btn-sm" title="'. __('Language selector\\Change the language') .'">OK</button> <button type="submit" class="btn btn-default btn-sm" title="'. __('Language selector', 'Change the language') .'">OK</button>
</span> </span>
</div> </div>
</form>'; </form>';
} }
echo ' echo '
<h1><a href="' . Utils::get_server_name() . '" title="' . __('Generic\\Home') . ' - ' . NOMAPPLICATION . '">' . $img . '</a></h1> <h1><a href="' . Utils::get_server_name() . '" title="' . __('Generic', 'Home') . ' - ' . NOMAPPLICATION . '">' . $img . '</a></h1>
<h2 class="lead"><i>'. $titre .'</i></h2> <h2 class="lead"><i>'. $titre .'</i></h2>
<hr class="trait" role="presentation" /> <hr class="trait" role="presentation" />
</header> </header>
@ -48,7 +48,7 @@ function bandeau_titre($titre)
$tables = $connect->allTables(); $tables = $connect->allTables();
$diff = array_diff([Utils::table('comment'), Utils::table('poll'), Utils::table('slot'), Utils::table('vote')], $tables); $diff = array_diff([Utils::table('comment'), Utils::table('poll'), Utils::table('slot'), Utils::table('vote')], $tables);
if (0 != count($diff)) { if (0 != count($diff)) {
echo '<div class="alert alert-danger">'. __('Error\\Framadate is not properly installed, please check the "INSTALL" to setup the database before continuing.') .'</div>'; echo '<div class="alert alert-danger">'. __('Error', 'Framadate is not properly installed, please check the "INSTALL" to setup the database before continuing.') .'</div>';
bandeau_pied(); bandeau_pied();
die(); die();
} }

View File

@ -125,8 +125,8 @@ if (empty($_SESSION['form']->title) || empty($_SESSION['form']->admin_name) || (
} // Step 3/4 : Confirm poll creation and choose a removal date } // Step 3/4 : Confirm poll creation and choose a removal date
else if (isset($_POST['fin_sondage_autre'])) { else if (isset($_POST['fin_sondage_autre'])) {
Utils::print_header(__('Step 3\\Removal date and confirmation (3 on 3)')); Utils::print_header(__('Step 3', 'Removal date and confirmation (3 on 3)'));
bandeau_titre(__('Step 3\\Removal date and confirmation (3 on 3)')); bandeau_titre(__('Step 3', 'Removal date and confirmation (3 on 3)'));
// Store choices in $_SESSION // Store choices in $_SESSION
@ -153,17 +153,17 @@ if (empty($_SESSION['form']->title) || empty($_SESSION['form']->admin_name) || (
preg_match_all('/\[(.*?)\]\((.*?)\)/', $choice->getName(), $md_a); // Markdown [text](href) preg_match_all('/\[(.*?)\]\((.*?)\)/', $choice->getName(), $md_a); // Markdown [text](href)
if (isset($md_a_img[2][0]) && $md_a_img[2][0] != '' && isset($md_a_img[3][0]) && $md_a_img[3][0] != '') { // [![alt](src)](href) if (isset($md_a_img[2][0]) && $md_a_img[2][0] != '' && isset($md_a_img[3][0]) && $md_a_img[3][0] != '') { // [![alt](src)](href)
$li_subject_text = (isset($md_a_img[1][0]) && $md_a_img[1][0] != '') ? stripslashes($md_a_img[1][0]) : __('Generic\\Choice') . ' ' . ($i + 1); $li_subject_text = (isset($md_a_img[1][0]) && $md_a_img[1][0] != '') ? stripslashes($md_a_img[1][0]) : __('Generic', 'Choice') . ' ' . ($i + 1);
$li_subject_html = '<a href="' . $md_a_img[3][0] . '"><img src="' . $md_a_img[2][0] . '" class="img-responsive" alt="' . $li_subject_text . '" /></a>'; $li_subject_html = '<a href="' . $md_a_img[3][0] . '"><img src="' . $md_a_img[2][0] . '" class="img-responsive" alt="' . $li_subject_text . '" /></a>';
} elseif (isset($md_img[2][0]) && $md_img[2][0] != '') { // ![alt](src) } elseif (isset($md_img[2][0]) && $md_img[2][0] != '') { // ![alt](src)
$li_subject_text = (isset($md_img[1][0]) && $md_img[1][0] != '') ? stripslashes($md_img[1][0]) : __('Generic\\Choice') . ' ' . ($i + 1); $li_subject_text = (isset($md_img[1][0]) && $md_img[1][0] != '') ? stripslashes($md_img[1][0]) : __('Generic', 'Choice') . ' ' . ($i + 1);
$li_subject_html = '<img src="' . $md_img[2][0] . '" class="img-responsive" alt="' . $li_subject_text . '" />'; $li_subject_html = '<img src="' . $md_img[2][0] . '" class="img-responsive" alt="' . $li_subject_text . '" />';
} elseif (isset($md_a[2][0]) && $md_a[2][0] != '') { // [text](href) } elseif (isset($md_a[2][0]) && $md_a[2][0] != '') { // [text](href)
$li_subject_text = (isset($md_a[1][0]) && $md_a[1][0] != '') ? stripslashes($md_a[1][0]) : __('Generic\\Choice') . ' ' . ($i + 1); $li_subject_text = (isset($md_a[1][0]) && $md_a[1][0] != '') ? stripslashes($md_a[1][0]) : __('Generic', 'Choice') . ' ' . ($i + 1);
$li_subject_html = '<a href="' . $md_a[2][0] . '">' . $li_subject_text . '</a>'; $li_subject_html = '<a href="' . $md_a[2][0] . '">' . $li_subject_text . '</a>';
} else { // text only } else { // text only
@ -184,33 +184,33 @@ if (empty($_SESSION['form']->title) || empty($_SESSION['form']->admin_name) || (
<div class="row"> <div class="row">
<div class="col-md-8 col-md-offset-2"> <div class="col-md-8 col-md-offset-2">
<div class="well summary"> <div class="well summary">
<h4>' . __('Step 3\\List of your choices') . '</h4> <h4>' . __('Step 3', 'List of your choices') . '</h4>
' . $summary . ' ' . $summary . '
</div> </div>
<div class="alert alert-info"> <div class="alert alert-info">
<p>' . __('Step 3\\Your poll will be automatically removed after') . ' ' . $config['default_poll_duration'] . ' ' . __('Generic\\days') . '.<br />' . __('Step 3\\You can set a closer removal date for it.') . '</p> <p>' . __('Step 3', 'Your poll will be automatically removed after') . ' ' . $config['default_poll_duration'] . ' ' . __('Generic', 'days') . '.<br />' . __('Step 3', 'You can set a closer removal date for it.') . '</p>
<div class="form-group"> <div class="form-group">
<label for="enddate" class="col-sm-5 control-label">' . __('Step 3\\Removal date:') . '</label> <label for="enddate" class="col-sm-5 control-label">' . __('Step 3', 'Removal date:') . '</label>
<div class="col-sm-6"> <div class="col-sm-6">
<div class="input-group date"> <div class="input-group date">
<span class="input-group-addon"><i class="glyphicon glyphicon-calendar text-info"></i></span> <span class="input-group-addon"><i class="glyphicon glyphicon-calendar text-info"></i></span>
<input type="text" class="form-control" id="enddate" data-date-format="' . __('Date\\dd/mm/yyyy') . '" aria-describedby="dateformat" name="enddate" value="' . $end_date_str . '" size="10" maxlength="10" placeholder="' . __("dd/mm/yyyy") . '" /> <input type="text" class="form-control" id="enddate" data-date-format="' . __('Date', 'dd/mm/yyyy') . '" aria-describedby="dateformat" name="enddate" value="' . $end_date_str . '" size="10" maxlength="10" placeholder="' . __("dd/mm/yyyy") . '" />
</div> </div>
</div> </div>
<span id="dateformat" class="sr-only">' . __('Date\\dd/mm/yyyy') . '</span> <span id="dateformat" class="sr-only">' . __('Date', 'dd/mm/yyyy') . '</span>
</div> </div>
</div> </div>
<div class="alert alert-warning"> <div class="alert alert-warning">
<p>' . __('Step 3\\Once you have confirmed the creation of your poll, you will be automatically redirected on the administration page of your poll.') . '</p>'; <p>' . __('Step 3', 'Once you have confirmed the creation of your poll, you will be automatically redirected on the administration page of your poll.') . '</p>';
if ($config['use_smtp'] == true) { if ($config['use_smtp'] == true) {
echo ' echo '
<p>' . __('Step 3\\Then, you will receive quickly two emails: one contening the link of your poll for sending it to the voters, the other contening the link to the administration page of your poll.') . '</p>'; <p>' . __('Step 3', 'Then, you will receive quickly two emails: one contening the link of your poll for sending it to the voters, the other contening the link to the administration page of your poll.') . '</p>';
} }
echo ' echo '
</div> </div>
<p class="text-right"> <p class="text-right">
<button class="btn btn-default" onclick="javascript:window.history.back();" title="' . __('Step 3\\Back to step 2') . '">' . __('Generic\\Back') . '</button> <button class="btn btn-default" onclick="javascript:window.history.back();" title="' . __('Step 3', 'Back to step 2') . '">' . __('Generic', 'Back') . '</button>
<button name="confirmecreation" value="confirmecreation" type="submit" class="btn btn-success">' . __('Step 3\\Create the poll') . '</button> <button name="confirmecreation" value="confirmecreation" type="submit" class="btn btn-success">' . __('Step 3', 'Create the poll') . '</button>
</p> </p>
</div> </div>
</div> </div>
@ -220,8 +220,8 @@ if (empty($_SESSION['form']->title) || empty($_SESSION['form']->admin_name) || (
// Step 2/4 : Select choices of the poll // Step 2/4 : Select choices of the poll
} else { } else {
Utils::print_header(__('Step 2 classic\\Poll subjects (2 on 3)')); Utils::print_header(__('Step 2 classic', 'Poll subjects (2 on 3)'));
bandeau_titre(__('Step 2 classic\\Poll subjects (2 on 3)')); bandeau_titre(__('Step 2 classic', 'Poll subjects (2 on 3)'));
echo ' echo '
<form name="formulaire" action="' . Utils::get_server_name() . 'create_classic_poll.php" method="POST" class="form-horizontal" role="form"> <form name="formulaire" action="' . Utils::get_server_name() . 'create_classic_poll.php" method="POST" class="form-horizontal" role="form">
@ -229,10 +229,10 @@ if (empty($_SESSION['form']->title) || empty($_SESSION['form']->admin_name) || (
<div class="col-md-8 col-md-offset-2">'; <div class="col-md-8 col-md-offset-2">';
echo ' echo '
<div class="alert alert-info"> <div class="alert alert-info">
<p>' . __('Step 2 classic\\To make a generic poll you need to propose at least two choices between differents subjects.') . '</p> <p>' . __('Step 2 classic', 'To make a generic poll you need to propose at least two choices between differents subjects.') . '</p>
<p>' . __('Step 2 classic\\You can add or remove additional choices with the buttons') . ' <span class="glyphicon glyphicon-minus text-info"></span><span class="sr-only">' . __('Generic\\Remove') . '</span> <span class="glyphicon glyphicon-plus text-success"></span><span class="sr-only">' . __('Generic\\Add') . '</span></p>'; <p>' . __('Step 2 classic', 'You can add or remove additional choices with the buttons') . ' <span class="glyphicon glyphicon-minus text-info"></span><span class="sr-only">' . __('Generic', 'Remove') . '</span> <span class="glyphicon glyphicon-plus text-success"></span><span class="sr-only">' . __('Generic', 'Add') . '</span></p>';
if ($config['user_can_add_img_or_link']) { if ($config['user_can_add_img_or_link']) {
echo ' <p>' . __('Step 2 classic\\It\'s possible to propose links or images by using') . ' <a href="http://' . $html_lang . '.wikipedia.org/wiki/Markdown">' . __('Step 2 classic\\the Markdown syntax') . '</a>.</p>'; echo ' <p>' . __('Step 2 classic', 'It\'s possible to propose links or images by using') . ' <a href="http://' . $html_lang . '.wikipedia.org/wiki/Markdown">' . __('Step 2 classic', 'the Markdown syntax') . '</a>.</p>';
} }
echo ' </div>' . "\n"; echo ' </div>' . "\n";
@ -243,11 +243,11 @@ if (empty($_SESSION['form']->title) || empty($_SESSION['form']->admin_name) || (
$choice = isset($choices[$i]) ? $choices[$i] : new Choice(); $choice = isset($choices[$i]) ? $choices[$i] : new Choice();
echo ' echo '
<div class="form-group choice-field"> <div class="form-group choice-field">
<label for="choice' . $i . '" class="col-sm-2 control-label">' . __('Generic\\Choice') . ' ' . ($i + 1) . '</label> <label for="choice' . $i . '" class="col-sm-2 control-label">' . __('Generic', 'Choice') . ' ' . ($i + 1) . '</label>
<div class="col-sm-10 input-group"> <div class="col-sm-10 input-group">
<input type="text" class="form-control" name="choices[]" size="40" value="' . $choice->getName() . '" id="choice' . $i . '" />'; <input type="text" class="form-control" name="choices[]" size="40" value="' . $choice->getName() . '" id="choice' . $i . '" />';
if ($config['user_can_add_img_or_link']) { if ($config['user_can_add_img_or_link']) {
echo '<span class="input-group-addon btn-link md-a-img" title="' . __('Step 2 classic\\Add a link or an image') . ' - ' . __('Generic\\Choice') . ' ' . ($i + 1) . '" ><span class="glyphicon glyphicon-picture"></span> <span class="glyphicon glyphicon-link"></span></span>'; echo '<span class="input-group-addon btn-link md-a-img" title="' . __('Step 2 classic', 'Add a link or an image') . ' - ' . __('Generic', 'Choice') . ' ' . ($i + 1) . '" ><span class="glyphicon glyphicon-picture"></span> <span class="glyphicon glyphicon-link"></span></span>';
} }
echo ' echo '
</div> </div>
@ -257,13 +257,13 @@ if (empty($_SESSION['form']->title) || empty($_SESSION['form']->admin_name) || (
echo ' echo '
<div class="col-md-4"> <div class="col-md-4">
<div class="btn-group btn-group"> <div class="btn-group btn-group">
<button type="button" id="remove-a-choice" class="btn btn-default" title="' . __('Step 2 classic\\Remove a choice') . '"><span class="glyphicon glyphicon-minus text-info"></span><span class="sr-only">' . __('Generic\\Remove') . '</span></button> <button type="button" id="remove-a-choice" class="btn btn-default" title="' . __('Step 2 classic', 'Remove a choice') . '"><span class="glyphicon glyphicon-minus text-info"></span><span class="sr-only">' . __('Generic', 'Remove') . '</span></button>
<button type="button" id="add-a-choice" class="btn btn-default" title="' . __('Step 2 classic\\Add a choice') . '"><span class="glyphicon glyphicon-plus text-success"></span><span class="sr-only">' . __('Generic\\Add') . '</span></button> <button type="button" id="add-a-choice" class="btn btn-default" title="' . __('Step 2 classic', 'Add a choice') . '"><span class="glyphicon glyphicon-plus text-success"></span><span class="sr-only">' . __('Generic', 'Add') . '</span></button>
</div> </div>
</div> </div>
<div class="col-md-8 text-right"> <div class="col-md-8 text-right">
<a class="btn btn-default" href="' . Utils::get_server_name() . 'infos_sondage.php?choix_sondage=autre" title="' . __('Step 2\\Back to step 1') . '">' . __('Generic\\Back') . '</a> <a class="btn btn-default" href="' . Utils::get_server_name() . 'infos_sondage.php?choix_sondage=autre" title="' . __('Step 2', 'Back to step 1') . '">' . __('Generic', 'Back') . '</a>
<button name="fin_sondage_autre" value="' . __('Generic\\Next') . '" type="submit" class="btn btn-success disabled" title="' . __('Step 2\\Go to step 3') . '">' . __('Generic\\Next') . '</button> <button name="fin_sondage_autre" value="' . __('Generic', 'Next') . '" type="submit" class="btn btn-success disabled" title="' . __('Step 2', 'Go to step 3') . '">' . __('Generic', 'Next') . '</button>
</div> </div>
</div> </div>
</div> </div>
@ -271,27 +271,27 @@ if (empty($_SESSION['form']->title) || empty($_SESSION['form']->admin_name) || (
<div class="modal-dialog"> <div class="modal-dialog">
<div class="modal-content"> <div class="modal-content">
<div class="modal-header"> <div class="modal-header">
<button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">' . __('Generic\\Close') . '</span></button> <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">' . __('Generic', 'Close') . '</span></button>
<p class="modal-title" id="md-a-imgModalLabel">' . __('Step 2 classic\\Add a link or an image') . '</p> <p class="modal-title" id="md-a-imgModalLabel">' . __('Step 2 classic', 'Add a link or an image') . '</p>
</div> </div>
<div class="modal-body"> <div class="modal-body">
<p class="alert alert-info">' . __('Step 2 classic\\These fields are optional. You can add a link, an image or both.') . '</p> <p class="alert alert-info">' . __('Step 2 classic', 'These fields are optional. You can add a link, an image or both.') . '</p>
<div class="form-group"> <div class="form-group">
<label for="md-img"><span class="glyphicon glyphicon-picture"></span> ' . __('Step 2 classic\\URL of the image') . '</label> <label for="md-img"><span class="glyphicon glyphicon-picture"></span> ' . __('Step 2 classic', 'URL of the image') . '</label>
<input id="md-img" type="text" placeholder="http://…" class="form-control" size="40" /> <input id="md-img" type="text" placeholder="http://…" class="form-control" size="40" />
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="md-a"><span class="glyphicon glyphicon-link"></span> ' . __('Generic\\Link') . '</label> <label for="md-a"><span class="glyphicon glyphicon-link"></span> ' . __('Generic', 'Link') . '</label>
<input id="md-a" type="text" placeholder="http://…" class="form-control" size="40" /> <input id="md-a" type="text" placeholder="http://…" class="form-control" size="40" />
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="md-text">' . __('Step 2 classic\\Alternative text') . '</label> <label for="md-text">' . __('Step 2 classic', 'Alternative text') . '</label>
<input id="md-text" type="text" class="form-control" size="40" /> <input id="md-text" type="text" class="form-control" size="40" />
</div> </div>
</div> </div>
<div class="modal-footer"> <div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal">' . __('Generic\\Cancel') . '</button> <button type="button" class="btn btn-default" data-dismiss="modal">' . __('Generic', 'Cancel') . '</button>
<button type="button" class="btn btn-primary">' . __('Generic\\Add') . '</button> <button type="button" class="btn btn-primary">' . __('Generic', 'Add') . '</button>
</div> </div>
</div> </div>
</div> </div>

View File

@ -43,13 +43,13 @@ if (is_readable('bandeaux_local.php')) {
// Step 1/4 : error if $_SESSION from info_sondage are not valid // Step 1/4 : error if $_SESSION from info_sondage are not valid
if (!isset($_SESSION['form']->title) || !isset($_SESSION['form']->admin_name) || ($config['use_smtp'] && !isset($_SESSION['form']->admin_mail))) { if (!isset($_SESSION['form']->title) || !isset($_SESSION['form']->admin_name) || ($config['use_smtp'] && !isset($_SESSION['form']->admin_mail))) {
Utils::print_header ( __('Error\\Error!') ); Utils::print_header ( __('Error', 'Error!') );
bandeau_titre(__('Error\\Error!')); bandeau_titre(__('Error', 'Error!'));
echo ' echo '
<div class="alert alter-danger"> <div class="alert alter-danger">
<h3>' . __('Error\\You haven\'t filled the first section of the poll creation.') . ' !</h3> <h3>' . __('Error', 'You haven\'t filled the first section of the poll creation.') . ' !</h3>
<p>' . __('Error\\Back to the homepage of') . ' ' . '<a href="' . Utils::get_server_name() . '">' . NOMAPPLICATION . '</a>.</p> <p>' . __('Error', 'Back to the homepage of') . ' ' . '<a href="' . Utils::get_server_name() . '">' . NOMAPPLICATION . '</a>.</p>
</div>'; </div>';
@ -94,20 +94,20 @@ if (!isset($_SESSION['form']->title) || !isset($_SESSION['form']->admin_name) ||
// Send confirmation by mail if enabled // Send confirmation by mail if enabled
if ($config['use_smtp'] === true) { 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 = __('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 .= "\n\n"; $message .= "\n\n";
$message .= stripslashes(html_entity_decode($_SESSION['form']->admin_name, ENT_QUOTES, 'UTF-8')) . ' ' . __('Mail\\hast just created a poll called') . ' : "' . stripslashes(htmlspecialchars_decode($_SESSION['form']->title, ENT_QUOTES)) . "\".\n"; $message .= stripslashes(html_entity_decode($_SESSION['form']->admin_name, ENT_QUOTES, 'UTF-8')) . ' ' . __('Mail', 'hast just created a poll called') . ' : "' . stripslashes(htmlspecialchars_decode($_SESSION['form']->title, ENT_QUOTES)) . "\".\n";
$message .= __('Mail\\Thanks for filling the poll at the link above') . " :\n\n%s\n\n" . __('Mail\\Thanks for your confidence.') . "\n" . NOMAPPLICATION; $message .= __('Mail', 'Thanks for filling the poll at the link above') . " :\n\n%s\n\n" . __('Mail', 'Thanks for your confidence.') . "\n" . NOMAPPLICATION;
$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"); $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");
$message_admin .= " :\n\n" . "%s \n\n" . __('Mail\\Thanks for your confidence.') . "\n" . NOMAPPLICATION; $message_admin .= " :\n\n" . "%s \n\n" . __('Mail', 'Thanks for your confidence.') . "\n" . NOMAPPLICATION;
$message = sprintf($message, Utils::getUrlSondage($poll_id)); $message = sprintf($message, Utils::getUrlSondage($poll_id));
$message_admin = sprintf($message_admin, Utils::getUrlSondage($admin_poll_id, true)); $message_admin = sprintf($message_admin, Utils::getUrlSondage($admin_poll_id, true));
if ($mailService->isValidEmail($_SESSION['form']->admin_mail)) { if ($mailService->isValidEmail($_SESSION['form']->admin_mail)) {
$mailService->send($_SESSION['form']->admin_mail, '[' . NOMAPPLICATION . '][' . __('Mail\\Author\'s message') . '] ' . __('Generic\\Poll') . ' : ' . stripslashes(htmlspecialchars_decode($_SESSION['form']->title, ENT_QUOTES)), $message_admin); $mailService->send($_SESSION['form']->admin_mail, '[' . NOMAPPLICATION . '][' . __('Mail', 'Author\'s message') . '] ' . __('Generic', 'Poll') . ' : ' . stripslashes(htmlspecialchars_decode($_SESSION['form']->title, ENT_QUOTES)), $message_admin);
$mailService->send($_SESSION['form']->admin_mail, '[' . NOMAPPLICATION . '][' . __('Mail\\For sending to the polled users') . '] ' . __('Generic\\Poll') . ' : ' . stripslashes(htmlspecialchars_decode($_SESSION['form']->title, ENT_QUOTES)), $message); $mailService->send($_SESSION['form']->admin_mail, '[' . NOMAPPLICATION . '][' . __('Mail', 'For sending to the polled users') . '] ' . __('Generic', 'Poll') . ' : ' . stripslashes(htmlspecialchars_decode($_SESSION['form']->title, ENT_QUOTES)), $message);
} }
} }
@ -154,8 +154,8 @@ if (!isset($_SESSION['form']->title) || !isset($_SESSION['form']->admin_name) ||
// Step 3/4 : Confirm poll creation // Step 3/4 : Confirm poll creation
if (!empty($_POST['choixheures']) && !isset($_SESSION['form']->totalchoixjour)) { if (!empty($_POST['choixheures']) && !isset($_SESSION['form']->totalchoixjour)) {
Utils::print_header ( __('Step 3\\Removal date and confirmation (3 on 3)') ); Utils::print_header ( __('Step 3', 'Removal date and confirmation (3 on 3)') );
bandeau_titre(__('Step 3\\Removal date and confirmation (3 on 3)')); bandeau_titre(__('Step 3', 'Removal date and confirmation (3 on 3)'));
$_SESSION['form']->sortChoices(); $_SESSION['form']->sortChoices();
$last_date = $_SESSION['form']->lastChoice()->getName(); $last_date = $_SESSION['form']->lastChoice()->getName();
@ -181,34 +181,34 @@ if (!isset($_SESSION['form']->title) || !isset($_SESSION['form']->admin_name) ||
<form name="formulaire" action="' . Utils::get_server_name() . 'create_date_poll.php" method="POST" class="form-horizontal" role="form"> <form name="formulaire" action="' . Utils::get_server_name() . 'create_date_poll.php" method="POST" class="form-horizontal" role="form">
<div class="row" id="selected-days"> <div class="row" id="selected-days">
<div class="col-md-8 col-md-offset-2"> <div class="col-md-8 col-md-offset-2">
<h3>'. __('Step 3\\Confirm the creation of your poll') .'</h3> <h3>'. __('Step 3', 'Confirm the creation of your poll') .'</h3>
<div class="well summary"> <div class="well summary">
<h4>'. __('Step 3\\List of your choices').'</h4> <h4>'. __('Step 3', 'List of your choices').'</h4>
'. $summary .' '. $summary .'
</div> </div>
<div class="alert alert-info clearfix"> <div class="alert alert-info clearfix">
<p>' . __('Step 3\\Your poll will be automatically removed after') . ' ' . $config['default_poll_duration'] . ' ' . __('Generic\\days') . ' ' .__('Step 3\\after the last date of your poll:') . '<br />' . __('Step 3\\You can set a closer removal date for it.') .'</p> <p>' . __('Step 3', 'Your poll will be automatically removed after') . ' ' . $config['default_poll_duration'] . ' ' . __('Generic', 'days') . ' ' .__('Step 3', 'after the last date of your poll:') . '<br />' . __('Step 3', 'You can set a closer removal date for it.') .'</p>
<div class="form-group"> <div class="form-group">
<label for="enddate" class="col-sm-5 control-label">'. __('Step 3\\Removal date:') .'</label> <label for="enddate" class="col-sm-5 control-label">'. __('Step 3', 'Removal date:') .'</label>
<div class="col-sm-6"> <div class="col-sm-6">
<div class="input-group date"> <div class="input-group date">
<span class="input-group-addon"><i class="glyphicon glyphicon-calendar text-info"></i></span> <span class="input-group-addon"><i class="glyphicon glyphicon-calendar text-info"></i></span>
<input type="text" class="form-control" id="enddate" data-date-format="'. __('Date\\dd/mm/yyyy') .'" aria-describedby="dateformat" name="enddate" value="'.$end_date_str.'" size="10" maxlength="10" placeholder="'. __('dd/mm/yyyy') .'" /> <input type="text" class="form-control" id="enddate" data-date-format="'. __('Date', 'dd/mm/yyyy') .'" aria-describedby="dateformat" name="enddate" value="'.$end_date_str.'" size="10" maxlength="10" placeholder="'. __('dd/mm/yyyy') .'" />
</div> </div>
</div> </div>
<span id="dateformat" class="sr-only">('. __("Date\\dd/mm/yyyy") .')</span> <span id="dateformat" class="sr-only">('. __('Date', 'dd/mm/yyyy') .')</span>
</div> </div>
</div> </div>
<div class="alert alert-warning"> <div class="alert alert-warning">
<p>'. __('Step 3\\Once you have confirmed the creation of your poll, you will be automatically redirected on the administration page of your poll.'). '</p>'; <p>'. __('Step 3', 'Once you have confirmed the creation of your poll, you will be automatically redirected on the administration page of your poll.'). '</p>';
if($config['use_smtp'] == true) { if($config['use_smtp'] == true) {
echo '<p>' . __('Step 3\\Then, you will receive quickly two emails: one contening the link of your poll for sending it to the voters, the other contening the link to the administration page of your poll.') .'</p>'; echo '<p>' . __('Step 3', 'Then, you will receive quickly two emails: one contening the link of your poll for sending it to the voters, the other contening the link to the administration page of your poll.') .'</p>';
} }
echo ' echo '
</div> </div>
<p class="text-right"> <p class="text-right">
<button class="btn btn-default" onclick="javascript:window.history.back();" title="'. __('Step 3\\Back to step 2') . '">'. __('Generic\\Back') . '</button> <button class="btn btn-default" onclick="javascript:window.history.back();" title="'. __('Step 3', 'Back to step 2') . '">'. __('Generic', 'Back') . '</button>
<button name="confirmation" value="confirmation" type="submit" class="btn btn-success">'. __('Step 3\\Create the poll') . '</button> <button name="confirmation" value="confirmation" type="submit" class="btn btn-success">'. __('Step 3', 'Create the poll') . '</button>
</p> </p>
</div> </div>
</div> </div>
@ -218,18 +218,18 @@ if (!isset($_SESSION['form']->title) || !isset($_SESSION['form']->admin_name) ||
// Step 2/4 : Select dates of the poll // Step 2/4 : Select dates of the poll
} else { } else {
Utils::print_header(__('Step 2 date\\Poll dates (2 on 3)')); Utils::print_header(__('Step 2 date', 'Poll dates (2 on 3)'));
bandeau_titre(__('Step 2 date\\Poll dates (2 on 3)')); bandeau_titre(__('Step 2 date', 'Poll dates (2 on 3)'));
echo ' echo '
<form name="formulaire" action="' . Utils::get_server_name() . 'create_date_poll.php" method="POST" class="form-horizontal" role="form"> <form name="formulaire" action="' . Utils::get_server_name() . 'create_date_poll.php" method="POST" class="form-horizontal" role="form">
<div class="row" id="selected-days"> <div class="row" id="selected-days">
<div class="col-md-10 col-md-offset-1"> <div class="col-md-10 col-md-offset-1">
<h3>'. __('Step 2 date\\Choose the dates of your poll') .'</h3> <h3>'. __('Step 2 date', 'Choose the dates of your poll') .'</h3>
<div class="alert alert-info"> <div class="alert alert-info">
<p>'. __('Step 2 date\\To schedule an event you need to propose at least two choices (two hours for one day or two days).').'</p> <p>'. __('Step 2 date', 'To schedule an event you need to propose at least two choices (two hours for one day or two days).').'</p>
<p>'. __('Step 2 date\\You can add or remove additionnal days and hours with the buttons') .' <span class="glyphicon glyphicon-minus text-info"></span><span class="sr-only">'. __('Remove') .'</span> <span class="glyphicon glyphicon-plus text-success"></span><span class="sr-only">'. __('Add') .'</span></p> <p>'. __('Step 2 date', 'You can add or remove additionnal days and hours with the buttons') .' <span class="glyphicon glyphicon-minus text-info"></span><span class="sr-only">'. __('Remove') .'</span> <span class="glyphicon glyphicon-plus text-success"></span><span class="sr-only">'. __('Add') .'</span></p>
<p>'. __('Step 2 date\\For each selected day, you can choose, or not, meeting hours (e.g.: "8h", "8:30", "8h-10h", "evening", etc.)').'</p> <p>'. __('Step 2 date', 'For each selected day, you can choose, or not, meeting hours (e.g.: "8h", "8:30", "8h-10h", "evening", etc.)').'</p>
</div>'; </div>';
// Fields days : 3 by default // Fields days : 3 by default
@ -240,12 +240,12 @@ if (!isset($_SESSION['form']->title) || !isset($_SESSION['form']->admin_name) ||
<fieldset> <fieldset>
<div class="form-group"> <div class="form-group">
<legend> <legend>
<label class="sr-only" for="day'.$i.'">'. __('Generic\\Day') .' '. ($i+1) .'</label> <label class="sr-only" for="day'.$i.'">'. __('Generic', 'Day') .' '. ($i+1) .'</label>
<div class="input-group date col-xs-7"> <div class="input-group date col-xs-7">
<span class="input-group-addon"><i class="glyphicon glyphicon-calendar text-info"></i></span> <span class="input-group-addon"><i class="glyphicon glyphicon-calendar text-info"></i></span>
<input type="text" class="form-control" id="day'.$i.'" title="'. __('Generic\\Day') .' '. ($i+1) .'" data-date-format="'. __('Date\\dd/mm/yyyy') .'" aria-describedby="dateformat'.$i.'" name="days[]" value="'.$day_value.'" size="10" maxlength="10" placeholder="'. __('Date\\dd/mm/yyyy') .'" /> <input type="text" class="form-control" id="day'.$i.'" title="'. __('Generic', 'Day') .' '. ($i+1) .'" data-date-format="'. __('Date', 'dd/mm/yyyy') .'" aria-describedby="dateformat'.$i.'" name="days[]" value="'.$day_value.'" size="10" maxlength="10" placeholder="'. __('Date', 'dd/mm/yyyy') .'" />
</div> </div>
<span id="dateformat'.$i.'" class="sr-only">('. __('Date\\dd/mm/yyyy') .')</span> <span id="dateformat'.$i.'" class="sr-only">('. __('Date', 'dd/mm/yyyy') .')</span>
</legend>'."\n"; </legend>'."\n";
// Fields hours : 3 by default // Fields hours : 3 by default
@ -254,38 +254,38 @@ if (!isset($_SESSION['form']->title) || !isset($_SESSION['form']->admin_name) ||
$hour_value = isset($_SESSION['horaires'.$i][$j]) ? $_SESSION['horaires'.$i][$j] : ''; $hour_value = isset($_SESSION['horaires'.$i][$j]) ? $_SESSION['horaires'.$i][$j] : '';
echo ' echo '
<div class="col-sm-2"> <div class="col-sm-2">
<label for="d'.$i.'-h'.$j.'" class="sr-only control-label">'. __('Generic\\Time') .' '. ($j+1) .'</label> <label for="d'.$i.'-h'.$j.'" class="sr-only control-label">'. __('Generic', 'Time') .' '. ($j+1) .'</label>
<input type="text" class="form-control hours" title="'.$day_value.' - '. __('Generic\\Time') .' '. ($j+1) .'" placeholder="'. __('Generic\\Time') .' '. ($j+1) .'" id="d'.$i.'-h'.$j.'" name="horaires'.$i.'[]" value="'.$hour_value.'" /> <input type="text" class="form-control hours" title="'.$day_value.' - '. __('Generic', 'Time') .' '. ($j+1) .'" placeholder="'. __('Generic', 'Time') .' '. ($j+1) .'" id="d'.$i.'-h'.$j.'" name="horaires'.$i.'[]" value="'.$hour_value.'" />
</div>'."\n"; </div>'."\n";
} }
echo ' echo '
<div class="col-sm-2"><div class="btn-group btn-group-xs" style="margin-top: 5px;"> <div class="col-sm-2"><div class="btn-group btn-group-xs" style="margin-top: 5px;">
<button type="button" title="'. __('Step 2 date\\Remove an hour') .'" class="remove-an-hour btn btn-default"><span class="glyphicon glyphicon-minus text-info"></span><span class="sr-only">'. __("Remove an hour") .'</span></button> <button type="button" title="'. __('Step 2 date', 'Remove an hour') .'" class="remove-an-hour btn btn-default"><span class="glyphicon glyphicon-minus text-info"></span><span class="sr-only">'. __('Step 2 date', 'Remove an hour') .'</span></button>
<button type="button" title="'. __('Step 2 date\\Add an hour') .'" class="add-an-hour btn btn-default"><span class="glyphicon glyphicon-plus text-success"></span><span class="sr-only">'. __("Add an hour") .'</span></button> <button type="button" title="'. __('Step 2 date', 'Add an hour') .'" class="add-an-hour btn btn-default"><span class="glyphicon glyphicon-plus text-success"></span><span class="sr-only">'. __('Step 2 date', 'Add an hour') .'</span></button>
</div></div> </div></div>
</div> </div>
</fieldset>'; </fieldset>';
} }
echo ' echo '
<div class="col-md-4"> <div class="col-md-4">
<button type="button" id="copyhours" class="btn btn-default disabled" title="'. __('Step 2 date\\Copy hours of the first day') .'"><span class="glyphicon glyphicon-sort-by-attributes-alt text-info"></span><span class="sr-only">'. __('Step 2 date\\Copy hours of the first day') .'</span></button> <button type="button" id="copyhours" class="btn btn-default disabled" title="'. __('Step 2 date', 'Copy hours of the first day') .'"><span class="glyphicon glyphicon-sort-by-attributes-alt text-info"></span><span class="sr-only">'. __('Step 2 date', 'Copy hours of the first day') .'</span></button>
<div class="btn-group btn-group"> <div class="btn-group btn-group">
<button type="button" id="remove-a-day" class="btn btn-default disabled" title="'. __('Step 2 date\\Remove a day') .'"><span class="glyphicon glyphicon-minus text-info"></span><span class="sr-only">'. __('Step 2 date\\Remove a day') .'</span></button> <button type="button" id="remove-a-day" class="btn btn-default disabled" title="'. __('Step 2 date', 'Remove a day') .'"><span class="glyphicon glyphicon-minus text-info"></span><span class="sr-only">'. __('Step 2 date', 'Remove a day') .'</span></button>
<button type="button" id="add-a-day" class="btn btn-default" title="'. __('Step 2 date\\Add a day') .'"><span class="glyphicon glyphicon-plus text-success"></span><span class="sr-only">'. __('Step 2 date\\Add a day') .'</span></button> <button type="button" id="add-a-day" class="btn btn-default" title="'. __('Step 2 date', 'Add a day') .'"><span class="glyphicon glyphicon-plus text-success"></span><span class="sr-only">'. __('Step 2 date', 'Add a day') .'</span></button>
</div> </div>
</div> </div>
<div class="col-md-8 text-right"> <div class="col-md-8 text-right">
<div class="btn-group"> <div class="btn-group">
<button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown"> <button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown">
<span class="glyphicon glyphicon-remove text-danger"></span> '. __('Generic\\Remove') . ' <span class="caret"></span> <span class="glyphicon glyphicon-remove text-danger"></span> '. __('Generic', 'Remove') . ' <span class="caret"></span>
</button> </button>
<ul class="dropdown-menu" role="menu"> <ul class="dropdown-menu" role="menu">
<li><a id="resetdays" href="javascript:void(0)">'. __('Step 2 date\\Remove all days') .'</a></li> <li><a id="resetdays" href="javascript:void(0)">'. __('Step 2 date', 'Remove all days') .'</a></li>
<li><a id="resethours" href="javascript:void(0)">'. __('Step 2 date\\Remove all hours') .'</a></li> <li><a id="resethours" href="javascript:void(0)">'. __('Step 2 date', 'Remove all hours') .'</a></li>
</ul> </ul>
</div> </div>
<a class="btn btn-default" href="'.Utils::get_server_name().'infos_sondage.php?choix_sondage=date" title="'. __('Step 2\\Back to step 1') . '">'. __('Generic\\Back') . '</a> <a class="btn btn-default" href="'.Utils::get_server_name().'infos_sondage.php?choix_sondage=date" title="'. __('Step 2', 'Back to step 1') . '">'. __('Generic', 'Back') . '</a>
<button name="choixheures" value="'. __('Generic\\Next') .'" type="submit" class="btn btn-success disabled" title="'. __('Step 2\\Go to step 3') . '">'. __('Generic\\Next') .'</button> <button name="choixheures" value="'. __('Generic', 'Next') .'" type="submit" class="btn btn-success disabled" title="'. __('Step 2', 'Go to step 3') . '">'. __('Generic', 'Next') .'</button>
</div> </div>
</div> </div>
</div> </div>

View File

@ -110,14 +110,14 @@ if (!empty($_POST['poursuivre'])) {
} else { } else {
// Title Erreur ! // Title Erreur !
Utils::print_header( __('Generic\\Error!').' - '.__('Step 1\\Poll creation (1 on 3)') ); Utils::print_header( __('Generic', 'Error!').' - '.__('Step 1', 'Poll creation (1 on 3)') );
} }
} else { } else {
// Title OK (formulaire pas encore rempli) // Title OK (formulaire pas encore rempli)
Utils::print_header( __('Step 1\\Poll creation (1 on 3)') ); Utils::print_header( __('Step 1', 'Poll creation (1 on 3)') );
} }
bandeau_titre( __('Step 1\\Poll creation (1 on 3)') ); bandeau_titre( __('Step 1', 'Poll creation (1 on 3)') );
/* /*
* Préparation des messages d'erreur * Préparation des messages d'erreur
@ -150,37 +150,37 @@ if (!empty($_POST['poursuivre'])) {
if (empty($_POST['title'])) { if (empty($_POST['title'])) {
$errors['title']['aria'] = 'aria-describeby="poll_title_error" '; $errors['title']['aria'] = 'aria-describeby="poll_title_error" ';
$errors['title']['class'] = ' has-error'; $errors['title']['class'] = ' has-error';
$errors['title']['msg'] = '<div class="alert alert-danger" ><p id="poll_title_error">' . __('Error\\Enter a title') . '</p></div>'; $errors['title']['msg'] = '<div class="alert alert-danger" ><p id="poll_title_error">' . __('Error', 'Enter a title') . '</p></div>';
} elseif ($error_on_title) { } elseif ($error_on_title) {
$errors['title']['aria'] = 'aria-describeby="poll_title_error" '; $errors['title']['aria'] = 'aria-describeby="poll_title_error" ';
$errors['title']['class'] = ' has-error'; $errors['title']['class'] = ' has-error';
$errors['title']['msg'] = '<div class="alert alert-danger"><p id="poll_title_error">' . __('Error\\Something is wrong with the format') . '</p></div>'; $errors['title']['msg'] = '<div class="alert alert-danger"><p id="poll_title_error">' . __('Error', 'Something is wrong with the format') . '</p></div>';
} }
if ($error_on_description) { if ($error_on_description) {
$errors['description']['aria'] = 'aria-describeby="poll_comment_error" '; $errors['description']['aria'] = 'aria-describeby="poll_comment_error" ';
$errors['description']['class'] = ' has-error'; $errors['description']['class'] = ' has-error';
$errors['description']['msg'] = '<div class="alert alert-danger"><p id="poll_comment_error">' . __('Error\\Something is wrong with the format') . '</p></div>'; $errors['description']['msg'] = '<div class="alert alert-danger"><p id="poll_comment_error">' . __('Error', 'Something is wrong with the format') . '</p></div>';
} }
if (empty($_POST['name'])) { if (empty($_POST['name'])) {
$errors['name']['aria'] = 'aria-describeby="poll_name_error" '; $errors['name']['aria'] = 'aria-describeby="poll_name_error" ';
$errors['name']['class'] = ' has-error'; $errors['name']['class'] = ' has-error';
$errors['name']['msg'] = '<div class="alert alert-danger"><p id="poll_name_error">' . __('Error\\Enter a name') . '</p></div>'; $errors['name']['msg'] = '<div class="alert alert-danger"><p id="poll_name_error">' . __('Error', 'Enter a name') . '</p></div>';
} elseif ($error_on_name) { } elseif ($error_on_name) {
$errors['name']['aria'] = 'aria-describeby="poll_name_error" '; $errors['name']['aria'] = 'aria-describeby="poll_name_error" ';
$errors['name']['class'] = ' has-error'; $errors['name']['class'] = ' has-error';
$errors['name']['msg'] = '<div class="alert alert-danger"><p id="poll_name_error">' . __('Error\\Something is wrong with the format') . '</p></div>'; $errors['name']['msg'] = '<div class="alert alert-danger"><p id="poll_name_error">' . __('Error', 'Something is wrong with the format') . '</p></div>';
} }
if (empty($_POST['mail'])) { if (empty($_POST['mail'])) {
$errors['email']['aria'] = 'aria-describeby="poll_name_error" '; $errors['email']['aria'] = 'aria-describeby="poll_name_error" ';
$errors['email']['class'] = ' has-error'; $errors['email']['class'] = ' has-error';
$errors['email']['msg'] = '<div class="alert alert-danger"><p id="poll_email_error">' . __('Error\\Enter an email address') . '</p></div>'; $errors['email']['msg'] = '<div class="alert alert-danger"><p id="poll_email_error">' . __('Error', 'Enter an email address') . '</p></div>';
} elseif ($error_on_mail) { } elseif ($error_on_mail) {
$errors['email']['aria'] = 'aria-describeby="poll_email_error" '; $errors['email']['aria'] = 'aria-describeby="poll_email_error" ';
$errors['email']['class'] = ' has-error'; $errors['email']['class'] = ' has-error';
$errors['email']['msg'] = '<div class="alert alert-danger"><p id="poll_email_error">' . __('Error\\The address is not correct! You should enter a valid email address (like r.stallman@outlock.com) in order to receive the link to your poll.') . '</p></div>'; $errors['email']['msg'] = '<div class="alert alert-danger"><p id="poll_email_error">' . __('Error', 'The address is not correct! You should enter a valid email address (like r.stallman@outlock.com) in order to receive the link to your poll.') . '</p></div>';
} }
} }
/* /*
@ -220,25 +220,25 @@ echo '
<form name="formulaire" id="formulaire" action="' . Utils::get_server_name() . 'infos_sondage.php" method="POST" class="form-horizontal" role="form"> <form name="formulaire" id="formulaire" action="' . Utils::get_server_name() . 'infos_sondage.php" method="POST" class="form-horizontal" role="form">
<div class="alert alert-info"> <div class="alert alert-info">
<p>'. __('Step 1\\You are in the poll creation section.').' <br /> '.__('Step 1\\Required fields cannot be left blank.') .'</p> <p>'. __('Step 1', 'You are in the poll creation section.').' <br /> '.__('Step 1', 'Required fields cannot be left blank.') .'</p>
</div> </div>
<div class="form-group'.$errors['title']['class'].'"> <div class="form-group'.$errors['title']['class'].'">
<label for="poll_title" class="col-sm-4 control-label">' . __('Step 1\\Poll title') . ' *</label> <label for="poll_title" class="col-sm-4 control-label">' . __('Step 1', 'Poll title') . ' *</label>
<div class="col-sm-8"> <div class="col-sm-8">
<input id="poll_title" type="text" name="title" class="form-control" '.$errors['title']['aria'].' value="'. fromPostOrEmpty('title') .'" /> <input id="poll_title" type="text" name="title" class="form-control" '.$errors['title']['aria'].' value="'. fromPostOrEmpty('title') .'" />
</div> </div>
</div> </div>
'.$errors['title']['msg'].' '.$errors['title']['msg'].'
<div class="form-group'.$errors['description']['class'].'"> <div class="form-group'.$errors['description']['class'].'">
<label for="poll_comments" class="col-sm-4 control-label">'. __('Generic\\Description') .'</label> <label for="poll_comments" class="col-sm-4 control-label">'. __('Generic', 'Description') .'</label>
<div class="col-sm-8"> <div class="col-sm-8">
<textarea id="poll_comments" name="description" class="form-control" '.$errors['description']['aria'].' rows="5">'. fromPostOrEmpty('description') .'</textarea> <textarea id="poll_comments" name="description" class="form-control" '.$errors['description']['aria'].' rows="5">'. fromPostOrEmpty('description') .'</textarea>
</div> </div>
</div> </div>
'.$errors['description']['msg'].' '.$errors['description']['msg'].'
<div class="form-group'.$errors['name']['class'].'"> <div class="form-group'.$errors['name']['class'].'">
<label for="yourname" class="col-sm-4 control-label">'. __('Generic\\Your name') .' *</label> <label for="yourname" class="col-sm-4 control-label">'. __('Generic', 'Your name') .' *</label>
<div class="col-sm-8"> <div class="col-sm-8">
'.$input_name.' '.$input_name.'
</div> </div>
@ -247,7 +247,7 @@ echo '
if ($config['use_smtp']==true) { if ($config['use_smtp']==true) {
echo ' echo '
<div class="form-group'.$errors['email']['class'].'"> <div class="form-group'.$errors['email']['class'].'">
<label for="email" class="col-sm-4 control-label">'. __('Generic\\Your email address') .' *<br /><span class="small">'. __('Generic\\(in the format name@mail.com)') .'</span></label> <label for="email" class="col-sm-4 control-label">'. __('Generic', 'Your email address') .' *<br /><span class="small">'. __('Generic', '(in the format name@mail.com)') .'</span></label>
<div class="col-sm-8"> <div class="col-sm-8">
'.$input_email.' '.$input_email.'
</div> </div>
@ -259,7 +259,7 @@ echo '
<div class="col-sm-offset-4 col-sm-8"> <div class="col-sm-offset-4 col-sm-8">
<div class="checkbox"> <div class="checkbox">
<label> <label>
<input type=checkbox name="editable" '.$editable.' id="editable">'. __('Step 1\\Voters can modify their vote themselves.') .' <input type=checkbox name="editable" '.$editable.' id="editable">'. __('Step 1', 'Voters can modify their vote themselves.') .'
</label> </label>
</div> </div>
</div> </div>
@ -269,7 +269,7 @@ if ($config['use_smtp']==true) {
<div class="col-sm-offset-4 col-sm-8"> <div class="col-sm-offset-4 col-sm-8">
<div class="checkbox"> <div class="checkbox">
<label> <label>
<input type=checkbox name="receiveNewVotes" '.$receiveNewVotes.' id="receiveNewVotes">'. __('Step 1\\To receive an email for each new vote.') .' <input type=checkbox name="receiveNewVotes" '.$receiveNewVotes.' id="receiveNewVotes">'. __('Step 1', 'To receive an email for each new vote.') .'
</label> </label>
</div> </div>
</div> </div>
@ -278,7 +278,7 @@ if ($config['use_smtp']==true) {
<div class="col-sm-offset-4 col-sm-8"> <div class="col-sm-offset-4 col-sm-8">
<div class="checkbox"> <div class="checkbox">
<label> <label>
<input type=checkbox name="receiveNewComments" '.$receiveNewComments.' id="receiveNewComments">'. __('Step 1\\To receive an email for each new comment.') .' <input type=checkbox name="receiveNewComments" '.$receiveNewComments.' id="receiveNewComments">'. __('Step 1', 'To receive an email for each new comment.') .'
</label> </label>
</div> </div>
</div> </div>
@ -287,7 +287,7 @@ if ($config['use_smtp']==true) {
echo ' echo '
<p class="text-right"> <p class="text-right">
<input type="hidden" name="choix_sondage" value="'. $choix_sondage .'"/> <input type="hidden" name="choix_sondage" value="'. $choix_sondage .'"/>
<button name="poursuivre" value="'. $choix_sondage .'" type="submit" class="btn btn-success" title="'. __('Step 1\\Go to step 2') . '">'. __('Generic\\Next') . '</button> <button name="poursuivre" value="'. $choix_sondage .'" type="submit" class="btn btn-success" title="'. __('Step 1', 'Go to step 2') . '">'. __('Generic', 'Next') . '</button>
</p> </p>
<script type="text/javascript">document.formulaire.title.focus();</script> <script type="text/javascript">document.formulaire.title.focus();</script>
@ -297,11 +297,11 @@ echo '
</div> </div>
<noscript> <noscript>
<div class="alert alert-danger">'. <div class="alert alert-danger">'.
__('Step 1\\Javascript is disabled on your browser. Its activation is required to create a poll.') __('Step 1', 'Javascript is disabled on your browser. Its activation is required to create a poll.')
.'</div> .'</div>
</noscript> </noscript>
<div id="cookie-warning" class="alert alert-danger" style="display:none">'. <div id="cookie-warning" class="alert alert-danger" style="display:none">'.
__('Step 1\\Cookies are disabled on your browser. Theirs activation is required to create a poll.') __('Step 1', 'Cookies are disabled on your browser. Theirs activation is required to create a poll.')
.'</div> .'</div>
'; ';

View File

@ -161,6 +161,7 @@
"Poll saved": "Umfrage gespeichert", "Poll saved": "Umfrage gespeichert",
"Vote added": "vote hinzugefügt", "Vote added": "vote hinzugefügt",
"Vote updated": "vote aktualisiert", "Vote updated": "vote aktualisiert",
"Poll fully deleted": "Umfrage vollständig gelöscht",
"Vote deleted": "vote gelöscht", "Vote deleted": "vote gelöscht",
"All votes deleted": "Alle Stimmen werden gelöscht", "All votes deleted": "Alle Stimmen werden gelöscht",
"Back to the poll": "Zurück zur Umfrage", "Back to the poll": "Zurück zur Umfrage",
@ -173,6 +174,8 @@
"Confirm removal of all comments of the poll": "Entfernen aller Kommentare der Umfrage bestätigen", "Confirm removal of all comments of the poll": "Entfernen aller Kommentare der Umfrage bestätigen",
"Keep the comments": "Halten Sie die Kommentare", "Keep the comments": "Halten Sie die Kommentare",
"Remove the comments": "Entfernen Sie die Kommentare", "Remove the comments": "Entfernen Sie die Kommentare",
"Comment deleted": "Kommentar gelöscht",
"All comments deleted": "Alle Kommentare gelöscht",
"The poll has been deleted": "Die Umfrage wurde gelöscht", "The poll has been deleted": "Die Umfrage wurde gelöscht",
"Keep votes": "Halten Stimmen", "Keep votes": "Halten Stimmen",
"Keep comments": "Halten Sie Kommentare", "Keep comments": "Halten Sie Kommentare",

View File

@ -160,6 +160,7 @@
"Keep the poll": "Keep the poll", "Keep the poll": "Keep the poll",
"Your poll has been removed!": "Your poll has been removed!", "Your poll has been removed!": "Your poll has been removed!",
"Poll saved": "Poll saved", "Poll saved": "Poll saved",
"Poll fully deleted": "Poll fully deleted",
"Vote added": "Vote added", "Vote added": "Vote added",
"Vote updated": "Vote updated", "Vote updated": "Vote updated",
"Vote deleted": "Vote deleted", "Vote deleted": "Vote deleted",
@ -172,6 +173,8 @@
"Keep the votes": "Keep the votes", "Keep the votes": "Keep the votes",
"Remove the votes": "Remove the votes", "Remove the votes": "Remove the votes",
"Confirm removal of all comments of the poll": "Confirm removal of all comments of the poll", "Confirm removal of all comments of the poll": "Confirm removal of all comments of the poll",
"Comment deleted": "Comment deleted",
"All comments deleted": "All comments deleted",
"Keep the comments": "Keep the comments", "Keep the comments": "Keep the comments",
"Remove the comments": "Remove the comments", "Remove the comments": "Remove the comments",
"The poll has been deleted": "The poll has been deleted", "The poll has been deleted": "The poll has been deleted",

View File

@ -160,6 +160,7 @@
"Your poll has been removed!": "Su encuesta ha sido borrado!", "Your poll has been removed!": "Su encuesta ha sido borrado!",
"Poll saved": "ES_Sondage sauvegardé", "Poll saved": "ES_Sondage sauvegardé",
"Vote added": "ES_Vote ajouté", "Vote added": "ES_Vote ajouté",
"Poll fully deleted": "ES_Sondage complètement supprimé",
"Vote updated": "ES_Vote mis à jour", "Vote updated": "ES_Vote mis à jour",
"Vote deleted": "ES_Vote supprimé", "Vote deleted": "ES_Vote supprimé",
"All votes deleted": "ES_Tous les votes ont été supprimés", "All votes deleted": "ES_Tous les votes ont été supprimés",
@ -173,6 +174,8 @@
"Confirm removal of all comments of the poll": "ES_Confirmer la suppression de tous les commentaires de ce sondage", "Confirm removal of all comments of the poll": "ES_Confirmer la suppression de tous les commentaires de ce sondage",
"Keep the comments": "ES_Garder les commentaires", "Keep the comments": "ES_Garder les commentaires",
"Remove the comments": "ES_Supprimer les commentaires", "Remove the comments": "ES_Supprimer les commentaires",
"Comment deleted": "ES_Commentaire supprimé",
"All comments deleted": "ES_Tous les commentaires ont été supprimés",
"The poll has been deleted": "ES_Le sondage a été supprimé", "The poll has been deleted": "ES_Le sondage a été supprimé",
"Keep votes": "ES_Garder les votes", "Keep votes": "ES_Garder les votes",
"Keep comments": "ES_Garder les commentaires", "Keep comments": "ES_Garder les commentaires",

View File

@ -159,6 +159,7 @@
"Keep the poll": "Je garde le sondage", "Keep the poll": "Je garde le sondage",
"Your poll has been removed!": "Votre sondage a été supprimé !", "Your poll has been removed!": "Votre sondage a été supprimé !",
"Poll saved": "Sondage sauvegardé", "Poll saved": "Sondage sauvegardé",
"Poll fully deleted": "Sondage complètement supprimé",
"Vote added": "Vote ajouté", "Vote added": "Vote ajouté",
"Vote updated": "Vote mis à jour", "Vote updated": "Vote mis à jour",
"Vote deleted": "Vote supprimé", "Vote deleted": "Vote supprimé",
@ -173,6 +174,8 @@
"Confirm removal of all comments of the poll": "Confirmer la suppression de tous les commentaires de ce sondage", "Confirm removal of all comments of the poll": "Confirmer la suppression de tous les commentaires de ce sondage",
"Keep the comments": "Garder les commentaires", "Keep the comments": "Garder les commentaires",
"Remove the comments": "Supprimer les commentaires", "Remove the comments": "Supprimer les commentaires",
"Comment deleted": "Commentaire supprimé",
"All comments deleted": "Tous les commentaires ont été supprimés",
"The poll has been deleted": "Le sondage a été supprimé", "The poll has been deleted": "Le sondage a été supprimé",
"Keep votes": "Garder les votes", "Keep votes": "Garder les votes",
"Keep comments": "Garder les commentaires", "Keep comments": "Garder les commentaires",

View File

@ -3,36 +3,36 @@
{block name=main} {block name=main}
<form action="{$admin_poll_id|poll_url:true}" method="POST"> <form action="{$admin_poll_id|poll_url:true}" method="POST">
<div class="alert alert-info text-center"> <div class="alert alert-info text-center">
<h2>{__('adminstuds\\Column\'s adding')}</h2> <h2>{__('adminstuds', 'Column\'s adding')}</h2>
{if $format === 'D'} {if $format === 'D'}
<div class="form-group"> <div class="form-group">
<label for="newdate" class="col-md-4">{__('Generic\\Day')}</label> <label for="newdate" class="col-md-4">{__('Generic', 'Day')}</label>
<div class="col-md-8"> <div class="col-md-8">
<div class="input-group date"> <div class="input-group date">
<span class="input-group-addon"><i class="glyphicon glyphicon-calendar"></i></span> <span class="input-group-addon"><i class="glyphicon glyphicon-calendar"></i></span>
<input type="text" id="newdate" data-date-format="{__('Date\\dd/mm/yyyy')}" aria-describedby="dateformat" name="newdate" class="form-control" placeholder="{__('Date\\dd/mm/yyyy')}" /> <input type="text" id="newdate" data-date-format="{__('Date', 'dd/mm/yyyy')}" aria-describedby="dateformat" name="newdate" class="form-control" placeholder="{__('Date', 'dd/mm/yyyy')}" />
</div> </div>
<span id="dateformat" class="sr-only">({__('Date\\dd/mm/yyyy')})</span> <span id="dateformat" class="sr-only">({__('Date', 'dd/mm/yyyy')})</span>
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="newmoment" class="col-md-4">{__('Generic\\Time')}</label> <label for="newmoment" class="col-md-4">{__('Generic', 'Time')}</label>
<div class="col-md-8"> <div class="col-md-8">
<input type="text" id="newmoment" name="newmoment" class="form-control" /> <input type="text" id="newmoment" name="newmoment" class="form-control" />
</div> </div>
</div> </div>
{else} {else}
<div class="form-group"> <div class="form-group">
<label for="choice" class="col-md-4">{__('Generic\\Choice')}</label> <label for="choice" class="col-md-4">{__('Generic', 'Choice')}</label>
<div class="col-md-8"> <div class="col-md-8">
<input type="text" id="choice" name="choice" class="form-control" /> <input type="text" id="choice" name="choice" class="form-control" />
</div> </div>
</div> </div>
{/if} {/if}
<div class="form-group"> <div class="form-group">
<button class="btn btn-default" type="submit" name="back">{__('adminstuds\\Back to the poll')}</button> <button class="btn btn-default" type="submit" name="back">{__('adminstuds', 'Back to the poll')}</button>
<button type="submit" name="confirm_add_slot" class="btn btn-success">{__('adminstuds\\Add a column')}</button> <button type="submit" name="confirm_add_slot" class="btn btn-success">{__('adminstuds', 'Add a column')}</button>
</div> </div>
</div> </div>
</form> </form>

View File

@ -3,8 +3,8 @@
{block 'main'} {block 'main'}
<div class="row"> <div class="row">
<div class="col-xs-12"> <div class="col-xs-12">
<a href="{'admin'|resource}">{__('Admin\\Back to administration')}</a> <a href="{'admin'|resource}">{__('Admin', 'Back to administration')}</a>
</div> </div>
</div> </div>
{block 'admin_main'}{/block} {block 'admin_main'}{/block}
{/block} {/block}

View File

@ -3,18 +3,18 @@
{block 'main'} {block 'main'}
<div class="row"> <div class="row">
<div class="col-md-6 col-xs-12"> <div class="col-md-6 col-xs-12">
<a href="./polls.php"><h2>{__('Admin\\Polls')}</h2></a> <a href="./polls.php"><h2>{__('Admin', 'Polls')}</h2></a>
</div> </div>
<div class="col-md-6 col-xs-12"> <div class="col-md-6 col-xs-12">
<a href="./migration.php"><h2>{__('Admin\\Migration')}</h2></a> <a href="./migration.php"><h2>{__('Admin', 'Migration')}</h2></a>
</div> </div>
<div class="col-md-6 col-xs-12"> <div class="col-md-6 col-xs-12">
<a href="./purge.php"><h2>{__('Admin\\Purge')}</h2></a> <a href="./purge.php"><h2>{__('Admin', 'Purge')}</h2></a>
</div> </div>
{if $logsAreReadable} {if $logsAreReadable}
<div class="col-md-6 col-xs-12"> <div class="col-md-6 col-xs-12">
<a href="./logs.php"><h2>{__('Admin\\Logs')}</h2></a> <a href="./logs.php"><h2>{__('Admin', 'Logs')}</h2></a>
</div> </div>
{/if} {/if}
</div> </div>
{/block} {/block}

View File

@ -3,37 +3,37 @@
{block 'admin_main'} {block 'admin_main'}
<div class="row"> <div class="row">
<div class="col-xs-12 col-md-4"> <div class="col-xs-12 col-md-4">
<h2>{__('Admin\\Summary')}</h2> <h2>{__('Admin', 'Summary')}</h2>
{__('Admin\\Succeeded:')} <span class="label label-warning">{$countSucceeded|html} / {$countTotal|html}</span> {__('Admin', 'Succeeded:')} <span class="label label-warning">{$countSucceeded|html} / {$countTotal|html}</span>
<br/> <br/>
{__('Admin\\Failed:')} <span class="label label-danger">{$countFailed|html} / {$countTotal|html}</span> {__('Admin', 'Failed:')} <span class="label label-danger">{$countFailed|html} / {$countTotal|html}</span>
<br/> <br/>
{__('Admin\\Skipped:')} <span class="label label-info">{$countSkipped|html} / {$countTotal|html}</span> {__('Admin', 'Skipped:')} <span class="label label-info">{$countSkipped|html} / {$countTotal|html}</span>
</div> </div>
<div class="col-xs-12 col-md-4"> <div class="col-xs-12 col-md-4">
<h2>{__('Admin\\Success')}</h2> <h2>{__('Admin', 'Success')}</h2>
<ul> <ul>
{foreach $success as $s} {foreach $success as $s}
<li>{$s|html}</li> <li>{$s|html}</li>
{foreachelse} {foreachelse}
<li>{__('Admin\\Nothing')}</li> <li>{__('Admin', 'Nothing')}</li>
{/foreach} {/foreach}
</ul> </ul>
</div> </div>
<div class="col-xs-12 col-md-4"> <div class="col-xs-12 col-md-4">
<h2>{__('Admin\\Fail')}</h2> <h2>{__('Admin', 'Fail')}</h2>
<ul> <ul>
{foreach $fail as $f} {foreach $fail as $f}
<li>{$f|html}</li> <li>{$f|html}</li>
{foreachelse} {foreachelse}
<li>{__('Admin\\Nothing')}</li> <li>{__('Admin', 'Nothing')}</li>
{/foreach} {/foreach}
</ul> </ul>
</div> </div>
<div class="col-xs-12 well well-sm"> <div class="col-xs-12 well well-sm">
{__('Generic\\Page generated in')} {$time} {__('Generic\\seconds')} {__('Generic', 'Page generated in')} {$time} {__('Generic', 'seconds')}
</div> </div>
</div> </div>
{/block} {/block}

View File

@ -6,31 +6,31 @@
{block 'admin_main'} {block 'admin_main'}
<div class="panel panel-default" id="poll_search"> <div class="panel panel-default" id="poll_search">
<div class="panel-heading">{__('Generic\\Search')}</div> <div class="panel-heading">{__('Generic', 'Search')}</div>
<div class="panel-body" style="display: none;"> <div class="panel-body" style="display: none;">
<form action="" method="GET"> <form action="" method="GET">
<div class="row"> <div class="row">
<div class="col-md-6"> <div class="col-md-6">
<div class="form-group"> <div class="form-group">
<label for="poll" class="control-label">{__('Admin\\Poll ID')}</label> <label for="poll" class="control-label">{__('Admin', 'Poll ID')}</label>
<input type="text" name="poll" id="poll" class="form-control" <input type="text" name="poll" id="poll" class="form-control"
value="{$search['poll']|html}"/> value="{$search['poll']|html}"/>
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="name" class="control-label">{__('Admin\\Author')}</label> <label for="name" class="control-label">{__('Admin', 'Author')}</label>
<input type="text" name="name" id="name" class="form-control" <input type="text" name="name" id="name" class="form-control"
value="{$search['name']|html}"/> value="{$search['name']|html}"/>
</div> </div>
</div> </div>
<div class="col-md-6"> <div class="col-md-6">
<div class="form-group"> <div class="form-group">
<label for="title" class="control-label">{__('Admin\\Title')}</label> <label for="title" class="control-label">{__('Admin', 'Title')}</label>
<input type="text" name="title" id="title" class="form-control" <input type="text" name="title" id="title" class="form-control"
value="{$search['title']|html}"/> value="{$search['title']|html}"/>
</div> </div>
</div> </div>
</div> </div>
<input type="submit" value="{__('Generic\\Search')}" class="btn btn-default"/> <input type="submit" value="{__('Generic', 'Search')}" class="btn btn-default"/>
</form> </form>
</div> </div>
</div> </div>
@ -39,13 +39,13 @@
<input type="hidden" name="csrf" value="{$crsf}"/> <input type="hidden" name="csrf" value="{$crsf}"/>
{if $poll_to_delete} {if $poll_to_delete}
<div class="alert alert-warning text-center"> <div class="alert alert-warning text-center">
<h3>{__('adminstuds\\Confirm removal of the poll')} "{$poll_to_delete->id|html}"</h3> <h3>{__('adminstuds', 'Confirm removal of the poll')} "{$poll_to_delete->id|html}"</h3>
<p> <p>
<button class="btn btn-default" type="submit" value="1" <button class="btn btn-default" type="submit" value="1"
name="annullesuppression">{__('adminstuds\\Keep the poll')}</button> name="annullesuppression">{__('adminstuds', 'Keep the poll')}</button>
<button type="submit" name="delete_confirm" value="{$poll_to_delete->id|html}" <button type="submit" name="delete_confirm" value="{$poll_to_delete->id|html}"
class="btn btn-danger">{__('adminstuds\\Delete the poll')}</button> class="btn btn-danger">{__('adminstuds', 'Delete the poll')}</button>
</p> </p>
</div> </div>
{/if} {/if}
@ -53,31 +53,31 @@
<div class="panel panel-default"> <div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
{$count} / {$total} {__('Admin\\polls in the database at this time')} {$count} / {$total} {__('Admin', 'polls in the database at this time')}
</div> </div>
<table class="table table-bordered table-polls"> <table class="table table-bordered table-polls">
<tr align="center"> <tr align="center">
<th scope="col"></th> <th scope="col"></th>
<th scope="col">{__('Admin\\Title')}</th> <th scope="col">{__('Admin', 'Title')}</th>
<th scope="col">{__('Admin\\Author')}</th> <th scope="col">{__('Admin', 'Author')}</th>
<th scope="col">{__('Admin\\Email')}</th> <th scope="col">{__('Admin', 'Email')}</th>
<th scope="col">{__('Admin\\Expiration date')}</th> <th scope="col">{__('Admin', 'Expiration date')}</th>
<th scope="col">{__('Admin\\Votes')}</th> <th scope="col">{__('Admin', 'Votes')}</th>
<th scope="col">{__('Admin\\Poll ID')}</th> <th scope="col">{__('Admin', 'Poll ID')}</th>
<th scope="col" colspan="3">{__('Admin\\Actions')}</th> <th scope="col" colspan="3">{__('Admin', 'Actions')}</th>
</tr> </tr>
{foreach $polls as $poll} {foreach $polls as $poll}
<tr align="center"> <tr align="center">
<td class="cell-format"> <td class="cell-format">
{if $poll->format === 'D'} {if $poll->format === 'D'}
<span class="glyphicon glyphicon-calendar" aria-hidden="true" <span class="glyphicon glyphicon-calendar" aria-hidden="true"
title="{__('Generic\\Date')}"></span> title="{__('Generic', 'Date')}"></span>
<span class="sr-only">{__('Generic\\Date')}</span> <span class="sr-only">{__('Generic', 'Date')}</span>
{else} {else}
<span class="glyphicon glyphicon-list-alt" aria-hidden="true" <span class="glyphicon glyphicon-list-alt" aria-hidden="true"
title="{__('Generic\\Classic')}"></span> title="{__('Generic', 'Classic')}"></span>
<span class="sr-only">{__('Generic\\Classic')}</span> <span class="sr-only">{__('Generic', 'Classic')}</span>
{/if} {/if}
</td> </td>
<td>{$poll->title|html}</td> <td>{$poll->title|html}</td>
@ -92,25 +92,25 @@
<td>{$poll->votes|html}</td> <td>{$poll->votes|html}</td>
<td>{$poll->id|html}</td> <td>{$poll->id|html}</td>
<td><a href="{$poll->id|poll_url|html}" class="btn btn-link" <td><a href="{$poll->id|poll_url|html}" class="btn btn-link"
title="{__('Admin\\See the poll')}"><span title="{__('Admin', 'See the poll')}"><span
class="glyphicon glyphicon-eye-open"></span><span class="glyphicon glyphicon-eye-open"></span><span
class="sr-only">{__('Admin\\See the poll')}</span></a></td> class="sr-only">{__('Admin', 'See the poll')}</span></a></td>
<td><a href="{$poll->admin_id|poll_url:true|html}" class="btn btn-link" <td><a href="{$poll->admin_id|poll_url:true|html}" class="btn btn-link"
title="{__('Admin\\Change the poll')}"><span title="{__('Admin', 'Change the poll')}"><span
class="glyphicon glyphicon-pencil"></span><span class="glyphicon glyphicon-pencil"></span><span
class="sr-only">{__('Admin\\Change the poll')}</span></a></td> class="sr-only">{__('Admin', 'Change the poll')}</span></a></td>
<td> <td>
<button type="submit" name="delete_poll" value="{$poll->id|html}" class="btn btn-link" <button type="submit" name="delete_poll" value="{$poll->id|html}" class="btn btn-link"
title="{__('Admin\\Deleted the poll')}"><span title="{__('Admin', 'Deleted the poll')}"><span
class="glyphicon glyphicon-trash text-danger"></span><span class="glyphicon glyphicon-trash text-danger"></span><span
class="sr-only">{__('Admin\\Deleted the poll')}</span> class="sr-only">{__('Admin', 'Deleted the poll')}</span>
</td> </td>
</tr> </tr>
{/foreach} {/foreach}
</table> </table>
<div class="panel-heading"> <div class="panel-heading">
{__('Admin\\Pages:')} {__('Admin', 'Pages:')}
{for $p=1 to $pages} {for $p=1 to $pages}
{if $p===$page} {if $p===$page}
<a href="{$SERVER_URL}admin/polls.php?page={$p}&{$search_query}" class="btn btn-danger" <a href="{$SERVER_URL}admin/polls.php?page={$p}&{$search_query}" class="btn btn-danger"
@ -122,4 +122,4 @@
</div> </div>
</div> </div>
</form> </form>
{/block} {/block}

View File

@ -7,7 +7,7 @@
<form action="" method="POST"> <form action="" method="POST">
<input type="hidden" name="csrf" value="{$crsf}"/> <input type="hidden" name="csrf" value="{$crsf}"/>
<div class="text-center"> <div class="text-center">
<button type="submit" name="action" value="purge" class="btn btn-warning">{__('Admin\\Purge the polls')} <span class="glyphicon glyphicon-trash text-danger"></span></button> <button type="submit" name="action" value="purge" class="btn btn-warning">{__('Admin', 'Purge the polls')} <span class="glyphicon glyphicon-trash text-danger"></span></button>
</div> </div>
</form> </form>
{/block} {/block}

View File

@ -3,9 +3,9 @@
{block name=main} {block name=main}
<form action="{$admin_poll_id|poll_url:true|html}" method="POST"> <form action="{$admin_poll_id|poll_url:true|html}" method="POST">
<div class="alert alert-danger text-center"> <div class="alert alert-danger text-center">
<h2>{__('adminstuds\\Confirm removal of all comments of the poll')}</h2> <h2>{__('adminstuds', 'Confirm removal of all comments of the poll')}</h2>
<p><button class="btn btn-default" type="submit" name="cancel">{__('adminstuds\\Keep the comments')}</button> <p><button class="btn btn-default" type="submit" name="cancel">{__('adminstuds', 'Keep the comments')}</button>
<button type="submit" name="confirm_remove_all_comments" class="btn btn-danger">{__('adminstuds\\Remove the comments')}</button></p> <button type="submit" name="confirm_remove_all_comments" class="btn btn-danger">{__('adminstuds', 'Remove the comments')}</button></p>
</div> </div>
</form> </form>
{/block} {/block}

View File

@ -3,9 +3,9 @@
{block name=main} {block name=main}
<form action="{$admin_poll_id|poll_url:true|html}" method="POST"> <form action="{$admin_poll_id|poll_url:true|html}" method="POST">
<div class="alert alert-danger text-center"> <div class="alert alert-danger text-center">
<h2>{__('adminstuds\\Confirm removal of the poll')}</h2> <h2>{__('adminstuds', 'Confirm removal of the poll')}</h2>
<p><button class="btn btn-default" type="submit" name="cancel">{__('adminstuds\\Keep the poll')}</button> <p><button class="btn btn-default" type="submit" name="cancel">{__('adminstuds', 'Keep the poll')}</button>
<button type="submit" name="confirm_delete_poll" class="btn btn-danger">{__('PollInfo\\Remove the poll')}</button></p> <button type="submit" name="confirm_delete_poll" class="btn btn-danger">{__('PollInfo', 'Remove the poll')}</button></p>
</div> </div>
</form> </form>
{/block} {/block}

View File

@ -3,9 +3,9 @@
{block name=main} {block name=main}
<form action="{$admin_poll_id|poll_url:true|html}" method="POST"> <form action="{$admin_poll_id|poll_url:true|html}" method="POST">
<div class="alert alert-danger text-center"> <div class="alert alert-danger text-center">
<h2>{__('adminstuds\\Confirm removal of all votes of the poll')}</h2> <h2>{__('adminstuds', 'Confirm removal of all votes of the poll')}</h2>
<p><button class="btn btn-default" type="submit" name="cancel">{__('adminstuds\\Keep votes')}</button> <p><button class="btn btn-default" type="submit" name="cancel">{__('adminstuds', 'Keep votes')}</button>
<button type="submit" name="confirm_remove_all_votes" class="btn btn-danger">{__('adminstuds\\Remove the votes')}</button></p> <button type="submit" name="confirm_remove_all_votes" class="btn btn-danger">{__('adminstuds', 'Remove the votes')}</button></p>
</div> </div>
</form> </form>
{/block} {/block}

View File

@ -3,6 +3,6 @@
{block name=main} {block name=main}
<div class="alert alert-warning text-center"> <div class="alert alert-warning text-center">
<h2>{$error|html}</h2> <h2>{$error|html}</h2>
<p>{__('Generic\\Back to the homepage of')} <a href="{$SERVER_URL|html}">{$APPLICATION_NAME|html}</a></p> <p>{__('Generic', 'Back to the homepage of')} <a href="{$SERVER_URL|html}">{$APPLICATION_NAME|html}</a></p>
</div> </div>
{/block} {/block}

View File

@ -2,19 +2,19 @@
{if count($langs)>1} {if count($langs)>1}
<form method="post" action="" class="hidden-print"> <form method="post" action="" class="hidden-print">
<div class="input-group input-group-sm pull-right col-md-2 col-xs-4"> <div class="input-group input-group-sm pull-right col-md-2 col-xs-4">
<select name="lang" class="form-control" title="{__('Language selector\\Select the language')}" > <select name="lang" class="form-control" title="{__('Language selector', 'Select the language')}" >
{foreach $langs as $lang_key=>$lang_value} {foreach $langs as $lang_key=>$lang_value}
<option lang="{substr($lang_key, 0, 2)}" {if substr($lang_key, 0, 2)==$html_lang}selected{/if} value="{$lang_key|html}">{$lang_value|html}</option> <option lang="{substr($lang_key, 0, 2)}" {if substr($lang_key, 0, 2)==$html_lang}selected{/if} value="{$lang_key|html}">{$lang_value|html}</option>
{/foreach} {/foreach}
</select> </select>
<span class="input-group-btn"> <span class="input-group-btn">
<button type="submit" class="btn btn-default btn-sm" title="{__('Language selector\\Change the language')}">OK</button> <button type="submit" class="btn btn-default btn-sm" title="{__('Language selector', 'Change the language')}">OK</button>
</span> </span>
</div> </div>
</form> </form>
{/if} {/if}
<h1><a href="{$SERVER_URL|html}" title="{__('Generic\\Home')} - {$APPLICATION_NAME|html}"><img src="{$TITLE_IMAGE|resource}" alt="{$APPLICATION_NAME|html}"/></a></h1> <h1><a href="{$SERVER_URL|html}" title="{__('Generic', 'Home')} - {$APPLICATION_NAME|html}"><img src="{$TITLE_IMAGE|resource}" alt="{$APPLICATION_NAME|html}"/></a></h1>
{if !empty($title)}<h2 class="lead"><i>{$title|html}</i></h2>{/if} {if !empty($title)}<h2 class="lead"><i>{$title|html}</i></h2>{/if}
<hr class="trait" role="presentation" /> <hr class="trait" role="presentation" />
</header> </header>

View File

@ -4,11 +4,11 @@
{* Comment list *} {* Comment list *}
{if $comments|count > 0} {if $comments|count > 0}
<h3>{__('Comments\\Comments of polled people')}</h3> <h3>{__('Comments', 'Comments of polled people')}</h3>
{foreach $comments as $comment} {foreach $comments as $comment}
<div class="comment"> <div class="comment">
{if $admin && !$expired} {if $admin && !$expired}
<button type="submit" name="delete_comment" value="{$comment->id|html}" class="btn btn-link" title="{__('Comments\\Remove the comment')}"><span class="glyphicon glyphicon-remove text-danger"></span><span class="sr-only">{__('Generic\\Remove')}</span></button> <button type="submit" name="delete_comment" value="{$comment->id|html}" class="btn btn-link" title="{__('Comments', 'Remove the comment')}"><span class="glyphicon glyphicon-remove text-danger"></span><span class="sr-only">{__('Generic', 'Remove')}</span></button>
{/if} {/if}
<b>{$comment->name|html}</b>&nbsp; <b>{$comment->name|html}</b>&nbsp;
<span class="comment">{nl2br($comment->comment|html)}</span> <span class="comment">{nl2br($comment->comment|html)}</span>
@ -20,17 +20,17 @@
{if $active && !$expired} {if $active && !$expired}
<div class="hidden-print alert alert-info"> <div class="hidden-print alert alert-info">
<div class="col-md-6 col-md-offset-3"> <div class="col-md-6 col-md-offset-3">
<fieldset id="add-comment"><legend>{__('Comments\\Add a comment to the poll')}</legend> <fieldset id="add-comment"><legend>{__('Comments', 'Add a comment to the poll')}</legend>
<div class="form-group"> <div class="form-group">
<label for="name" class="control-label">{__('Generic\\Your name')}</label> <label for="name" class="control-label">{__('Generic', 'Your name')}</label>
<input type="text" name="name" id="name" class="form-control" /> <input type="text" name="name" id="name" class="form-control" />
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="comment" class="control-label">{__('Comments\\Your comment')}</label> <label for="comment" class="control-label">{__('Comments', 'Your comment')}</label>
<textarea name="comment" id="comment" class="form-control" rows="2" cols="40"></textarea> <textarea name="comment" id="comment" class="form-control" rows="2" cols="40"></textarea>
</div> </div>
<div class="pull-right"> <div class="pull-right">
<input type="submit" name="add_comment" value="{__('Comments\\Send the comment')}" class="btn btn-success"> <input type="submit" name="add_comment" value="{__('Comments', 'Send the comment')}" class="btn btn-success">
</div> </div>
</fieldset> </fieldset>
</div> </div>

View File

@ -1,11 +1,11 @@
{if $active} {if $active}
<div class="alert alert-info"> <div class="alert alert-info">
<p>{__('studs\\If you want to vote in this poll, you have to give your name, choose the values that fit best for you and validate with the plus button at the end of the line.')}</p> <p>{__('studs', 'If you want to vote in this poll, you have to give your name, choose the values that fit best for you and validate with the plus button at the end of the line.')}</p>
<p aria-hidden="true"><b>{__('Generic\\Legend:')}</b> <span class="glyphicon glyphicon-ok"></span> = {__('Generic\\Yes')}, <b>(<span class="glyphicon glyphicon-ok"></span>)</b> = {__('Generic\\Ifneedbe')}, <span class="glyphicon glyphicon-ban-circle"></span> = {_('No')}</p> <p aria-hidden="true"><b>{__('Generic', 'Legend:')}</b> <span class="glyphicon glyphicon-ok"></span> = {__('Generic', 'Yes')}, <b>(<span class="glyphicon glyphicon-ok"></span>)</b> = {__('Generic', 'Ifneedbe')}, <span class="glyphicon glyphicon-ban-circle"></span> = {_('No')}</p>
</div> </div>
{else} {else}
<div class="alert alert-danger"> <div class="alert alert-danger">
<p>{__('studs\\POLL_LOCKED_WARNING')}</p> <p>{__('studs', 'POLL_LOCKED_WARNING')}</p>
<p aria-hidden="true"><b>{__('Generic\\Legend:')}</b> <span class="glyphicon glyphicon-ok"></span> = {__('Generic\\Yes')}, <b>(<span class="glyphicon glyphicon-ok"></span>)</b> = {__('Generic\\Ifneedbe')}, <span class="glyphicon glyphicon-ban-circle"></span> = {_('No')}</p> <p aria-hidden="true"><b>{__('Generic', 'Legend:')}</b> <span class="glyphicon glyphicon-ok"></span> = {__('Generic', 'Yes')}, <b>(<span class="glyphicon glyphicon-ok"></span>)</b> = {__('Generic', 'Ifneedbe')}, <span class="glyphicon glyphicon-ban-circle"></span> = {_('No')}</p>
</div> </div>
{/if} {/if}

View File

@ -1,7 +1,7 @@
<div class="alert alert-info"> <div class="alert alert-info">
<p>{__('adminstuds\\As poll administrator, you can change all the lines of this poll with this button')} <span class="glyphicon glyphicon-pencil"></span><span class="sr-only">{_('Edit')}</span>, <p>{__('adminstuds', 'As poll administrator, you can change all the lines of this poll with this button')} <span class="glyphicon glyphicon-pencil"></span><span class="sr-only">{_('Edit')}</span>,
{__('adminstuds\\remove a column or a line with')} <span class="glyphicon glyphicon-remove text-danger"></span><span class="sr-only">{_('Remove')}</span> {__('adminstuds', 'remove a column or a line with')} <span class="glyphicon glyphicon-remove text-danger"></span><span class="sr-only">{_('Remove')}</span>
{__('adminstuds\\and add a new column with')} <span class="glyphicon glyphicon-plus text-success"></span><span class="sr-only">{_('Add a column')}</span>.</p> {__('adminstuds', 'and add a new column with')} <span class="glyphicon glyphicon-plus text-success"></span><span class="sr-only">{_('Add a column')}</span>.</p>
<p>{__('adminstuds\\Finally, you can change the informations of this poll like the title, the comments or your email address.')}</p> <p>{__('adminstuds', 'Finally, you can change the informations of this poll like the title, the comments or your email address.')}</p>
<p aria-hidden="true"><strong>{__('Generic\\Legend:')}</strong> <span class="glyphicon glyphicon-ok"></span> = {__('Generic\\Yes')}, <b>(<span class="glyphicon glyphicon-ok"></span>)</b> = {__('Generic\\Ifneedbe')}, <span class="glyphicon glyphicon-ban-circle"></span> = {__('Generic\\No')}</p> <p aria-hidden="true"><strong>{__('Generic', 'Legend:')}</strong> <span class="glyphicon glyphicon-ok"></span> = {__('Generic', 'Yes')}, <b>(<span class="glyphicon glyphicon-ok"></span>)</b> = {__('Generic', 'Ifneedbe')}, <span class="glyphicon glyphicon-ban-circle"></span> = {__('Generic', 'No')}</p>
</div> </div>

View File

@ -4,15 +4,15 @@
<div class="jumbotron{if $admin} bg-danger{/if}"> <div class="jumbotron{if $admin} bg-danger{/if}">
<div class="row"> <div class="row">
<div id="title-form" class="col-md-7"> <div id="title-form" class="col-md-7">
<h3>{$poll->title|html}{if $admin && !$expired} <button class="btn btn-link btn-sm btn-edit" title="{__('PollInfo\\Edit the title')}"><span class="glyphicon glyphicon-pencil"></span><span class="sr-only">{__('Generic\\Edit')}</span></button>{/if}</h3> <h3>{$poll->title|html}{if $admin && !$expired} <button class="btn btn-link btn-sm btn-edit" title="{__('PollInfo', 'Edit the title')}"><span class="glyphicon glyphicon-pencil"></span><span class="sr-only">{__('Generic', 'Edit')}</span></button>{/if}</h3>
{if $admin && !$expired} {if $admin && !$expired}
<div class="hidden js-title"> <div class="hidden js-title">
<label class="sr-only" for="newtitle">{__('PollInfo\\Title')}</label> <label class="sr-only" for="newtitle">{__('PollInfo', 'Title')}</label>
<div class="input-group"> <div class="input-group">
<input type="text" class="form-control" id="newtitle" name="title" size="40" value="{$poll->title|html}" /> <input type="text" class="form-control" id="newtitle" name="title" size="40" value="{$poll->title|html}" />
<span class="input-group-btn"> <span class="input-group-btn">
<button type="submit" class="btn btn-success" name="update_poll_info" value="title" title="{__('PollInfo\\Save the new title')}"><span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic\\Save')}</span></button> <button type="submit" class="btn btn-success" name="update_poll_info" value="title" title="{__('PollInfo', 'Save the new title')}"><span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic', 'Save')}</span></button>
<button class="btn btn-link btn-cancel" title="{__('PollInfo\\Cancel the title edit')}"><span class="glyphicon glyphicon-remove"></span><span class="sr-only">{__('Generic\\Cancel')}</span></button> <button class="btn btn-link btn-cancel" title="{__('PollInfo', 'Cancel the title edit')}"><span class="glyphicon glyphicon-remove"></span><span class="sr-only">{__('Generic', 'Cancel')}</span></button>
</span> </span>
</div> </div>
</div> </div>
@ -20,17 +20,17 @@
</div> </div>
<div class="col-md-5 hidden-print"> <div class="col-md-5 hidden-print">
<div class="btn-group pull-right"> <div class="btn-group pull-right">
<button onclick="print(); return false;" class="btn btn-default"><span class="glyphicon glyphicon-print"></span> {__('PollInfo\\Print')}</button> <button onclick="print(); return false;" class="btn btn-default"><span class="glyphicon glyphicon-print"></span> {__('PollInfo', 'Print')}</button>
<a href="{$SERVER_URL|html}exportcsv.php?poll={$poll_id|html}" class="btn btn-default"><span class="glyphicon glyphicon-download-alt"></span> {__('PollInfo\\Export to CSV')}</a> <a href="{$SERVER_URL|html}exportcsv.php?poll={$poll_id|html}" class="btn btn-default"><span class="glyphicon glyphicon-download-alt"></span> {__('PollInfo', 'Export to CSV')}</a>
{if $admin && !$expired} {if $admin && !$expired}
<button type="button" class="btn btn-danger dropdown-toggle" data-toggle="dropdown"> <button type="button" class="btn btn-danger dropdown-toggle" data-toggle="dropdown">
<span class="glyphicon glyphicon-trash"></span> <span class="sr-only">{__('Generic\\Remove')}</span> <span class="caret"></span> <span class="glyphicon glyphicon-trash"></span> <span class="sr-only">{__('Generic', 'Remove')}</span> <span class="caret"></span>
</button> </button>
<ul class="dropdown-menu" role="menu"> <ul class="dropdown-menu" role="menu">
<li><button class="btn btn-link" type="submit" name="remove_all_votes">{__('PollInfo\\Remove all the votes') }</button></li> <li><button class="btn btn-link" type="submit" name="remove_all_votes">{__('PollInfo', 'Remove all the votes') }</button></li>
<li><button class="btn btn-link" type="submit" name="remove_all_comments">{__('PollInfo\\Remove all the comments')}</button></li> <li><button class="btn btn-link" type="submit" name="remove_all_comments">{__('PollInfo', 'Remove all the comments')}</button></li>
<li class="divider" role="presentation"></li> <li class="divider" role="presentation"></li>
<li><button class="btn btn-link" type="submit" name="delete_poll">{__('PollInfo\\Remove the poll')}</button></li> <li><button class="btn btn-link" type="submit" name="delete_poll">{__('PollInfo', 'Remove the poll')}</button></li>
</ul> </ul>
{/if} {/if}
</div> </div>
@ -38,16 +38,16 @@
</div> </div>
<div class="row"> <div class="row">
<div id="name-form" class="form-group col-md-5"> <div id="name-form" class="form-group col-md-5">
<h4 class="control-label">{__('PollInfo\\Initiator of the poll')}</h4> <h4 class="control-label">{__('PollInfo', 'Initiator of the poll')}</h4>
<p class="form-control-static">{$poll->admin_name|html}{if $admin && !$expired} <button class="btn btn-link btn-sm btn-edit" title="{__('PollInfo\\Edit the name')}"><span class="glyphicon glyphicon-pencil"></span><span class="sr-only">{__('Generic\\Edit')}</span></button>{/if}</p> <p class="form-control-static">{$poll->admin_name|html}{if $admin && !$expired} <button class="btn btn-link btn-sm btn-edit" title="{__('PollInfo', 'Edit the name')}"><span class="glyphicon glyphicon-pencil"></span><span class="sr-only">{__('Generic', 'Edit')}</span></button>{/if}</p>
{if $admin && !$expired} {if $admin && !$expired}
<div class="hidden js-name"> <div class="hidden js-name">
<label class="sr-only" for="newname">{__('PollInfo\\Initiator of the poll')}</label> <label class="sr-only" for="newname">{__('PollInfo', 'Initiator of the poll')}</label>
<div class="input-group"> <div class="input-group">
<input type="text" class="form-control" id="newname" name="name" size="40" value="{$poll->admin_name|html}" /> <input type="text" class="form-control" id="newname" name="name" size="40" value="{$poll->admin_name|html}" />
<span class="input-group-btn"> <span class="input-group-btn">
<button type="submit" class="btn btn-success" name="update_poll_info" value="name" title="{__('PollInfo\\Save the new name')}"><span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic\\Save')}</span></button> <button type="submit" class="btn btn-success" name="update_poll_info" value="name" title="{__('PollInfo', 'Save the new name')}"><span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic', 'Save')}</span></button>
<button class="btn btn-link btn-cancel" title="{__('PollInfo\\Cancel the name edit')}"><span class="glyphicon glyphicon-remove"></span><span class="sr-only">{__('Generic\\Cancel')}</span></button> <button class="btn btn-link btn-cancel" title="{__('PollInfo', 'Cancel the name edit')}"><span class="glyphicon glyphicon-remove"></span><span class="sr-only">{__('Generic', 'Cancel')}</span></button>
</span> </span>
</div> </div>
</div> </div>
@ -58,15 +58,15 @@
{if $admin} {if $admin}
<div class="form-group col-md-5"> <div class="form-group col-md-5">
<div id="email-form"> <div id="email-form">
<p>{$poll->admin_mail|html}{if !$expired} <button class="btn btn-link btn-sm btn-edit" title="{__('PollInfo\\Edit the email adress')}"><span class="glyphicon glyphicon-pencil"></span><span class="sr-only">{__('Generic\\Edit')}</span></button>{/if}</p> <p>{$poll->admin_mail|html}{if !$expired} <button class="btn btn-link btn-sm btn-edit" title="{__('PollInfo', 'Edit the email adress')}"><span class="glyphicon glyphicon-pencil"></span><span class="sr-only">{__('Generic', 'Edit')}</span></button>{/if}</p>
{if !$expired} {if !$expired}
<div class="hidden js-email"> <div class="hidden js-email">
<label class="sr-only" for="admin_mail">{__('PollInfo\\Email')}</label> <label class="sr-only" for="admin_mail">{__('PollInfo', 'Email')}</label>
<div class="input-group"> <div class="input-group">
<input type="text" class="form-control" id="admin_mail" name="admin_mail" size="40" value="{$poll->admin_mail|html}" /> <input type="text" class="form-control" id="admin_mail" name="admin_mail" size="40" value="{$poll->admin_mail|html}" />
<span class="input-group-btn"> <span class="input-group-btn">
<button type="submit" name="update_poll_info" value="admin_mail" class="btn btn-success" title="{__('PollInfo\\Save the email address')}"><span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic\\Save')}</span></button> <button type="submit" name="update_poll_info" value="admin_mail" class="btn btn-success" title="{__('PollInfo', 'Save the email address')}"><span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic', 'Save')}</span></button>
<button class="btn btn-link btn-cancel" title="{__('PollInfo\\Cancel the email address edit')}"><span class="glyphicon glyphicon-remove"></span><span class="sr-only">{__('Generic\\Cancel')}</span></button> <button class="btn btn-link btn-cancel" title="{__('PollInfo', 'Cancel the email address edit')}"><span class="glyphicon glyphicon-remove"></span><span class="sr-only">{__('Generic', 'Cancel')}</span></button>
</span> </span>
</div> </div>
</div> </div>
@ -75,14 +75,14 @@
</div> </div>
{/if} {/if}
<div class="form-group col-md-7" id="description-form"> <div class="form-group col-md-7" id="description-form">
<h4 class="control-label">{__('Generic\\Description')}{if $admin && !$expired} <button class="btn btn-link btn-sm btn-edit" title="{__('PollInfo\\Edit the description')}"><span class="glyphicon glyphicon-pencil"></span><span class="sr-only">{__('Generic\\Edit')}</span></button>{/if}</h4> <h4 class="control-label">{__('Generic', 'Description')}{if $admin && !$expired} <button class="btn btn-link btn-sm btn-edit" title="{__('PollInfo', 'Edit the description')}"><span class="glyphicon glyphicon-pencil"></span><span class="sr-only">{__('Generic', 'Edit')}</span></button>{/if}</h4>
<p class="form-control-static well">{$poll->description|html}</p> <p class="form-control-static well">{$poll->description|html}</p>
{if $admin && !$expired} {if $admin && !$expired}
<div class="hidden js-desc text-right"> <div class="hidden js-desc text-right">
<label class="sr-only" for="newdescription">{__('Generic\\Description')}</label> <label class="sr-only" for="newdescription">{__('Generic', 'Description')}</label>
<textarea class="form-control" id="newdescription" name="description" rows="2" cols="40">{$poll->description|html}</textarea> <textarea class="form-control" id="newdescription" name="description" rows="2" cols="40">{$poll->description|html}</textarea>
<button type="submit" id="btn-new-desc" name="update_poll_info" value="description" class="btn btn-sm btn-success" title="{__('PollInfo\\Save the description')}"><span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic\\Save')}</span></button> <button type="submit" id="btn-new-desc" name="update_poll_info" value="description" class="btn btn-sm btn-success" title="{__('PollInfo', 'Save the description')}"><span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic', 'Save')}</span></button>
<button class="btn btn-default btn-sm btn-cancel" title="{__('PollInfo\\Cancel the description edit')}"><span class="glyphicon glyphicon-remove"></span><span class="sr-only">{__('Generic\\Cancel')}</span></button> <button class="btn btn-default btn-sm btn-cancel" title="{__('PollInfo', 'Cancel the description edit')}"><span class="glyphicon glyphicon-remove"></span><span class="sr-only">{__('Generic', 'Cancel')}</span></button>
</div> </div>
{/if} {/if}
</div> </div>
@ -90,25 +90,25 @@
<div class="row"> <div class="row">
<div class="form-group form-group {if $admin}col-md-4{else}col-md-6{/if}"> <div class="form-group form-group {if $admin}col-md-4{else}col-md-6{/if}">
<label for="public-link"><a class="public-link" href="{$poll_id|poll_url|html}">{__('PollInfo\\Public link of the poll')} <span class="btn-link glyphicon glyphicon-link"></span></a></label> <label for="public-link"><a class="public-link" href="{$poll_id|poll_url|html}">{__('PollInfo', 'Public link of the poll')} <span class="btn-link glyphicon glyphicon-link"></span></a></label>
<input class="form-control" id="public-link" type="text" readonly="readonly" value="{$poll_id|poll_url}" /> <input class="form-control" id="public-link" type="text" readonly="readonly" value="{$poll_id|poll_url}" />
</div> </div>
{if $admin} {if $admin}
<div class="form-group col-md-4"> <div class="form-group col-md-4">
<label for="admin-link"><a class="admin-link" href="{$admin_poll_id|poll_url:true|html}">{__('PollInfo\\Admin link of the poll')} <span class="btn-link glyphicon glyphicon-link"></span></a></label> <label for="admin-link"><a class="admin-link" href="{$admin_poll_id|poll_url:true|html}">{__('PollInfo', 'Admin link of the poll')} <span class="btn-link glyphicon glyphicon-link"></span></a></label>
<input class="form-control" id="admin-link" type="text" readonly="readonly" value="{$admin_poll_id|poll_url:true|html}" /> <input class="form-control" id="admin-link" type="text" readonly="readonly" value="{$admin_poll_id|poll_url:true|html}" />
</div> </div>
<div id="expiration-form" class="form-group col-md-4"> <div id="expiration-form" class="form-group col-md-4">
<h4 class="control-label">{__('PollInfo\\Expiration date')}</h4> <h4 class="control-label">{__('PollInfo', 'Expiration date')}</h4>
<p>{$poll->end_date|date_format:$date_format['txt_date']|html}{if !$expired} <button class="btn btn-link btn-sm btn-edit" title="{__('PollInfo\\Edit the expiration date')}"><span class="glyphicon glyphicon-pencil"></span><span class="sr-only">{__('Generic\\Edit')}</span></button>{/if}</p> <p>{$poll->end_date|date_format:$date_format['txt_date']|html}{if !$expired} <button class="btn btn-link btn-sm btn-edit" title="{__('PollInfo', 'Edit the expiration date')}"><span class="glyphicon glyphicon-pencil"></span><span class="sr-only">{__('Generic', 'Edit')}</span></button>{/if}</p>
{if !$expired} {if !$expired}
<div class="hidden js-expiration"> <div class="hidden js-expiration">
<label class="sr-only" for="newexpirationdate">{__('PollInfo\\Expiration date')}</label> <label class="sr-only" for="newexpirationdate">{__('PollInfo', 'Expiration date')}</label>
<div class="input-group"> <div class="input-group">
<input type="text" class="form-control" id="newexpirationdate" name="expiration_date" size="40" value="{$poll->end_date|date_format:$date_format['txt_date']|html}" /> <input type="text" class="form-control" id="newexpirationdate" name="expiration_date" size="40" value="{$poll->end_date|date_format:$date_format['txt_date']|html}" />
<span class="input-group-btn"> <span class="input-group-btn">
<button type="submit" class="btn btn-success" name="update_poll_info" value="expiration_date" title="{__('PollInfo\\Save the new expiration date')}"><span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic\\Save')}</span></button> <button type="submit" class="btn btn-success" name="update_poll_info" value="expiration_date" title="{__('PollInfo', 'Save the new expiration date')}"><span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic', 'Save')}</span></button>
<button class="btn btn-link btn-cancel" title="{__('PollInfo\\Cancel the expiration date edit')}"><span class="glyphicon glyphicon-remove"></span><span class="sr-only">{__('Generic\\Cancel')}</span></button> <button class="btn btn-link btn-cancel" title="{__('PollInfo', 'Cancel the expiration date edit')}"><span class="glyphicon glyphicon-remove"></span><span class="sr-only">{__('Generic', 'Cancel')}</span></button>
</span> </span>
</div> </div>
</div> </div>
@ -124,30 +124,30 @@
{if $poll->editable} {if $poll->editable}
{$rule_id = 2} {$rule_id = 2}
{$rule_icon = '<span class="glyphicon glyphicon-edit"></span>'} {$rule_icon = '<span class="glyphicon glyphicon-edit"></span>'}
{$rule_txt = __('PollInfo\\Votes are editable')} {$rule_txt = __('PollInfo', 'Votes are editable')}
{else} {else}
{$rule_id = 1} {$rule_id = 1}
{$rule_icon = '<span class="glyphicon glyphicon-check"></span>'} {$rule_icon = '<span class="glyphicon glyphicon-check"></span>'}
{$rule_txt = __('PollInfo\\Votes and comments are open')} {$rule_txt = __('PollInfo', 'Votes and comments are open')}
{/if} {/if}
{else} {else}
{$rule_id = 0} {$rule_id = 0}
{$rule_icon = '<span class="glyphicon glyphicon-lock"></span>'} {$rule_icon = '<span class="glyphicon glyphicon-lock"></span>'}
{$rule_txt = __('PollInfo\\Votes and comments are locked')} {$rule_txt = __('PollInfo', 'Votes and comments are locked')}
{/if} {/if}
<p class="">{$rule_icon} {$rule_txt|html}{if !$expired} <button class="btn btn-link btn-sm btn-edit" title="{__('PollInfo\\Edit the poll rules')}"><span class="glyphicon glyphicon-pencil"></span><span class="sr-only">{__('Generic\\Edit')}</span></button>{/if}</p> <p class="">{$rule_icon} {$rule_txt|html}{if !$expired} <button class="btn btn-link btn-sm btn-edit" title="{__('PollInfo', 'Edit the poll rules')}"><span class="glyphicon glyphicon-pencil"></span><span class="sr-only">{__('Generic', 'Edit')}</span></button>{/if}</p>
{if !$expired} {if !$expired}
<div class="hidden js-poll-rules"> <div class="hidden js-poll-rules">
<label class="sr-only" for="rules">{__('PollInfo\\Poll rules')}</label> <label class="sr-only" for="rules">{__('PollInfo', 'Poll rules')}</label>
<div class="input-group"> <div class="input-group">
<select class="form-control" id="rules" name="rules"> <select class="form-control" id="rules" name="rules">
<option value="0"{if $rule_id==0} selected="selected"{/if}>{__('PollInfo\\Votes and comments are locked')}</option> <option value="0"{if $rule_id==0} selected="selected"{/if}>{__('PollInfo', 'Votes and comments are locked')}</option>
<option value="1"{if $rule_id==1} selected="selected"{/if}>{__('PollInfo\\Votes and comments are open')}</option> <option value="1"{if $rule_id==1} selected="selected"{/if}>{__('PollInfo', 'Votes and comments are open')}</option>
<option value="2"{if $rule_id==2} selected="selected"{/if}>{__('PollInfo\\Votes are editable')}</option> <option value="2"{if $rule_id==2} selected="selected"{/if}>{__('PollInfo', 'Votes are editable')}</option>
</select> </select>
<span class="input-group-btn"> <span class="input-group-btn">
<button type="submit" name="update_poll_info" value="rules" class="btn btn-success" title="{__('PollInfo\\Save the new rules')}"><span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic\\Save')}</span></button> <button type="submit" name="update_poll_info" value="rules" class="btn btn-success" title="{__('PollInfo', 'Save the new rules')}"><span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic', 'Save')}</span></button>
<button class="btn btn-link btn-cancel" title="{__('PollInfo\\Cancel the rules edit')}"><span class="glyphicon glyphicon-remove"></span><span class="sr-only">{__('Generic\\Cancel')}</span></button> <button class="btn btn-link btn-cancel" title="{__('PollInfo', 'Cancel the rules edit')}"><span class="glyphicon glyphicon-remove"></span><span class="sr-only">{__('Generic', 'Cancel')}</span></button>
</span> </span>
</div> </div>
</div> </div>

View File

@ -2,23 +2,23 @@
{$best_choices = [0]} {$best_choices = [0]}
{/if} {/if}
<h3>{__('Poll results\\Votes of the poll')}</h3> <h3>{__('Poll results', 'Votes of the poll')}</h3>
<div id="tableContainer" class="tableContainer"> <div id="tableContainer" class="tableContainer">
<form action="" method="POST" id="poll_form"> <form action="" method="POST" id="poll_form">
<table class="results"> <table class="results">
<caption class="sr-only">{__('Poll results\\Votes of the poll')} {$poll->title|html}</caption> <caption class="sr-only">{__('Poll results', 'Votes of the poll')} {$poll->title|html}</caption>
<thead> <thead>
{if $admin && !$expired} {if $admin && !$expired}
<tr class="hidden-print"> <tr class="hidden-print">
<th role="presentation"></th> <th role="presentation"></th>
{foreach $slots as $id=>$slot} {foreach $slots as $id=>$slot}
<td headers="C{$id}"> <td headers="C{$id}">
<button type="submit" name="delete_column" value="{$slot->title|html}" class="btn btn-link btn-sm" title="{__('adminstuds\\Remove the column')} {$slot->title|html}"><span class="glyphicon glyphicon-remove text-danger"></span><span class="sr-only">{__('Genric\\Remove')}</span></button> <button type="submit" name="delete_column" value="{$slot->title|html}" class="btn btn-link btn-sm" title="{__('adminstuds', 'Remove the column')} {$slot->title|html}"><span class="glyphicon glyphicon-remove text-danger"></span><span class="sr-only">{__('Genric', 'Remove')}</span></button>
</td> </td>
{/foreach} {/foreach}
<td> <td>
<button type="submit" name="add_slot" class="btn btn-link btn-sm" title="{__('adminstuds\\Add a column')}"><span class="glyphicon glyphicon-plus text-success"></span><span class="sr-only">{__('Poll results\\Add a column')}</span></button> <button type="submit" name="add_slot" class="btn btn-link btn-sm" title="{__('adminstuds', 'Add a column')}"><span class="glyphicon glyphicon-plus text-success"></span><span class="sr-only">{__('Poll results', 'Add a column')}</span></button>
</td> </td>
</tr> </tr>
{/if} {/if}
@ -40,7 +40,7 @@
<td class="bg-info" style="padding:5px"> <td class="bg-info" style="padding:5px">
<div class="input-group input-group-sm"> <div class="input-group input-group-sm">
<span class="input-group-addon"><span class="glyphicon glyphicon-user"></span></span> <span class="input-group-addon"><span class="glyphicon glyphicon-user"></span></span>
<input type="text" id="name" name="name" value="{$vote->name|html}" class="form-control" title="{__('Genric\\Your name')}" placeholder="{__('Genric\\Your name')}" /> <input type="text" id="name" name="name" value="{$vote->name|html}" class="form-control" title="{__('Genric', 'Your name')}" placeholder="{__('Genric', 'Your name')}" />
</div> </div>
</td> </td>
@ -50,26 +50,26 @@
<ul class="list-unstyled choice"> <ul class="list-unstyled choice">
<li class="yes"> <li class="yes">
<input type="radio" id="y-choice-{$id}" name="choices[{$id}]" value="2" {if $choice==2}checked {/if}/> <input type="radio" id="y-choice-{$id}" name="choices[{$id}]" value="2" {if $choice==2}checked {/if}/>
<label class="btn btn-default btn-xs" for="y-choice-{$id}" title="{__('Poll results\\Vote yes for')} {$slots[$id]->title|html}"> <label class="btn btn-default btn-xs" for="y-choice-{$id}" title="{__('Poll results', 'Vote yes for')} {$slots[$id]->title|html}">
<span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Genric\\Yes')}</span> <span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Genric', 'Yes')}</span>
</label> </label>
</li> </li>
<li class="ifneedbe"> <li class="ifneedbe">
<input type="radio" id="i-choice-{$id}" name="choices[{$id}]" value="1" {if $choice==1}checked {/if}/> <input type="radio" id="i-choice-{$id}" name="choices[{$id}]" value="1" {if $choice==1}checked {/if}/>
<label class="btn btn-default btn-xs" for="i-choice-{$id}" title="{__('Poll results\\Vote ifneedbe for')} {$slots[$id]->title|html}"> <label class="btn btn-default btn-xs" for="i-choice-{$id}" title="{__('Poll results', 'Vote ifneedbe for')} {$slots[$id]->title|html}">
(<span class="glyphicon glyphicon-ok"></span>)<span class="sr-only">{__('Genric\\Ifneedbe')}</span> (<span class="glyphicon glyphicon-ok"></span>)<span class="sr-only">{__('Genric', 'Ifneedbe')}</span>
</label> </label>
</li> </li>
<li class="no"> <li class="no">
<input type="radio" id="n-choice-{$id}" name="choices[{$id}]" value="0" {if $choice==0}checked {/if}/> <input type="radio" id="n-choice-{$id}" name="choices[{$id}]" value="0" {if $choice==0}checked {/if}/>
<label class="btn btn-default btn-xs" for="n-choice-{$id}" title="{__('Poll results\\Vote no for')} {$slots[$id]->title|html}"> <label class="btn btn-default btn-xs" for="n-choice-{$id}" title="{__('Poll results', 'Vote no for')} {$slots[$id]->title|html}">
<span class="glyphicon glyphicon-ban-circle"></span><span class="sr-only">{__('Genric\\No')}</span> <span class="glyphicon glyphicon-ban-circle"></span><span class="sr-only">{__('Genric', 'No')}</span>
</label> </label>
</li> </li>
</ul> </ul>
</td> </td>
{/foreach} {/foreach}
<td style="padding:5px"><button type="submit" class="btn btn-success btn-xs check-name" name="save" value="{$vote->id|html}" title="{__('Poll results\\Save the choices')} {$vote->name|html}">{__('Generic\\Save')}</button></td> <td style="padding:5px"><button type="submit" class="btn btn-success btn-xs check-name" name="save" value="{$vote->id|html}" title="{__('Poll results', 'Save the choices')} {$vote->name|html}">{__('Generic', 'Save')}</button></td>
{else} {else}
{* Voted line *} {* Voted line *}
@ -79,23 +79,23 @@
{foreach $vote->choices as $id=>$choice} {foreach $vote->choices as $id=>$choice}
{if $choice==2} {if $choice==2}
<td class="bg-success text-success" headers="C{$id}"><span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic\\Yes')}</span></td> <td class="bg-success text-success" headers="C{$id}"><span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic', 'Yes')}</span></td>
{elseif $choice==1} {elseif $choice==1}
<td class="bg-warning text-warning" headers="C{$id}">(<span class="glyphicon glyphicon-ok"></span>)<span class="sr-only">{__('Generic\\Ifneedbe')}</span></td> <td class="bg-warning text-warning" headers="C{$id}">(<span class="glyphicon glyphicon-ok"></span>)<span class="sr-only">{__('Generic', 'Ifneedbe')}</span></td>
{else} {else}
<td class="bg-danger" headers="C{$id}"><span class="sr-only">{__('Generic\\No')}</span></td> <td class="bg-danger" headers="C{$id}"><span class="sr-only">{__('Generic', 'No')}</span></td>
{/if} {/if}
{/foreach} {/foreach}
{if $active && $poll->editable && !$expired} {if $active && $poll->editable && !$expired}
<td> <td>
<button type="submit" class="btn btn-link btn-sm" name="edit_vote" value="{$vote->id|html}" title="{__('Poll results\\Edit the line:')} {$vote->name|html}"> <button type="submit" class="btn btn-link btn-sm" name="edit_vote" value="{$vote->id|html}" title="{__('Poll results', 'Edit the line:')} {$vote->name|html}">
<span class="glyphicon glyphicon-pencil"></span><span class="sr-only">{__('Generic\\Edit')}</span> <span class="glyphicon glyphicon-pencil"></span><span class="sr-only">{__('Generic', 'Edit')}</span>
</button> </button>
{if $admin} {if $admin}
<button type="submit" class="btn btn-link btn-sm" name="delete_vote" value="{$vote->id|html}" title="{__('Poll results\\Remove the line:')} {$vote->name|html}"> <button type="submit" class="btn btn-link btn-sm" name="delete_vote" value="{$vote->id|html}" title="{__('Poll results', 'Remove the line:')} {$vote->name|html}">
<span class="glyphicon glyphicon-remove text-danger"></span><span class="sr-only">{__('Generic\\Remove')}</span> <span class="glyphicon glyphicon-remove text-danger"></span><span class="sr-only">{__('Generic', 'Remove')}</span>
</button> </button>
{/if} {/if}
</td> </td>
@ -113,7 +113,7 @@
<td class="bg-info" style="padding:5px"> <td class="bg-info" style="padding:5px">
<div class="input-group input-group-sm"> <div class="input-group input-group-sm">
<span class="input-group-addon"><span class="glyphicon glyphicon-user"></span></span> <span class="input-group-addon"><span class="glyphicon glyphicon-user"></span></span>
<input type="text" id="name" name="name" class="form-control" title="{__('Generic\\Your name')}" placeholder="{__('Generic\\Your name')}" /> <input type="text" id="name" name="name" class="form-control" title="{__('Generic', 'Your name')}" placeholder="{__('Generic', 'Your name')}" />
</div> </div>
</td> </td>
{foreach $slots as $id=>$slot} {foreach $slots as $id=>$slot}
@ -121,26 +121,26 @@
<ul class="list-unstyled choice"> <ul class="list-unstyled choice">
<li class="yes"> <li class="yes">
<input type="radio" id="y-choice-{$id}" name="choices[{$id}]" value="2" /> <input type="radio" id="y-choice-{$id}" name="choices[{$id}]" value="2" />
<label class="btn btn-default btn-xs" for="y-choice-{$id}" title="{__('Poll results\\Vote yes for')} {$slot->title|html}"> <label class="btn btn-default btn-xs" for="y-choice-{$id}" title="{__('Poll results', 'Vote yes for')} {$slot->title|html}">
<span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic\\Yes')}</span> <span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic', 'Yes')}</span>
</label> </label>
</li> </li>
<li class="ifneedbe"> <li class="ifneedbe">
<input type="radio" id="i-choice-{$id}" name="choices[{$id}]" value="1" /> <input type="radio" id="i-choice-{$id}" name="choices[{$id}]" value="1" />
<label class="btn btn-default btn-xs" for="i-choice-{$id}" title="{__('Poll results\\Vote ifneedbe for')} {$slot->title|html}"> <label class="btn btn-default btn-xs" for="i-choice-{$id}" title="{__('Poll results', 'Vote ifneedbe for')} {$slot->title|html}">
(<span class="glyphicon glyphicon-ok"></span>)<span class="sr-only">{__('Generic\\Ifneedbe')}</span> (<span class="glyphicon glyphicon-ok"></span>)<span class="sr-only">{__('Generic', 'Ifneedbe')}</span>
</label> </label>
</li> </li>
<li class="no"> <li class="no">
<input type="radio" id="n-choice-{$id}" name="choices[{$id}]" value="0" checked/> <input type="radio" id="n-choice-{$id}" name="choices[{$id}]" value="0" checked/>
<label class="btn btn-default btn-xs" for="n-choice-{$id}" title="{__('Poll results\\Vote no for')} {$slot->title|html}"> <label class="btn btn-default btn-xs" for="n-choice-{$id}" title="{__('Poll results', 'Vote no for')} {$slot->title|html}">
<span class="glyphicon glyphicon-ban-circle"></span><span class="sr-only">{__('Generic\\No')}</span> <span class="glyphicon glyphicon-ban-circle"></span><span class="sr-only">{__('Generic', 'No')}</span>
</label> </label>
</li> </li>
</ul> </ul>
</td> </td>
{/foreach} {/foreach}
<td><button type="submit" class="btn btn-success btn-md check-name" name="save" title="{__('Poll results\\Save the choices')}">{__('Generic\\Save')}</button></td> <td><button type="submit" class="btn btn-success btn-md check-name" name="save" title="{__('Poll results', 'Save the choices')}">{__('Generic', 'Save')}</button></td>
</tr> </tr>
{/if} {/if}
@ -149,7 +149,7 @@
{$max = max($best_choices)} {$max = max($best_choices)}
{if $max > 0} {if $max > 0}
<tr id="addition"> <tr id="addition">
<td>{__('Poll results\\Addition')}</td> <td>{__('Poll results', 'Addition')}</td>
{foreach $best_choices as $best_choice} {foreach $best_choices as $best_choice}
{if $max == $best_choice} {if $max == $best_choice}
{$count_bests = $count_bests +1} {$count_bests = $count_bests +1}
@ -173,13 +173,13 @@
{if $max > 0} {if $max > 0}
<div class="row"> <div class="row">
{if $count_bests == 1} {if $count_bests == 1}
<div class="col-sm-12"><h3>{__('Poll results\\Best choice')}</h3></div> <div class="col-sm-12"><h3>{__('Poll results', 'Best choice')}</h3></div>
<div class="col-sm-6 col-sm-offset-3 alert alert-success"> <div class="col-sm-6 col-sm-offset-3 alert alert-success">
<p><span class="glyphicon glyphicon-star text-warning"></span>{__('Poll results\\The best choice at this time is:')}</p> <p><span class="glyphicon glyphicon-star text-warning"></span>{__('Poll results', 'The best choice at this time is:')}</p>
{elseif $count_bests > 1} {elseif $count_bests > 1}
<div class="col-sm-12"><h3>{__('Poll results\\Best choices')}</h3></div> <div class="col-sm-12"><h3>{__('Poll results', 'Best choices')}</h3></div>
<div class="col-sm-6 col-sm-offset-3 alert alert-success"> <div class="col-sm-6 col-sm-offset-3 alert alert-success">
<p><span class="glyphicon glyphicon-star text-warning"></span>{__('Poll results\\The bests choices at this time are:')}</p> <p><span class="glyphicon glyphicon-star text-warning"></span>{__('Poll results', 'The bests choices at this time are:')}</p>
{/if} {/if}
@ -192,7 +192,7 @@
{$i = $i+1} {$i = $i+1}
{/foreach} {/foreach}
</ul> </ul>
<p>{__('Generic\\with')} <b>{$max|html}</b> {if $max==1}{__('Generic\\vote')}{else}{__('Generic\\votes')}{/if}.</p> <p>{__('Generic', 'with')} <b>{$max|html}</b> {if $max==1}{__('Generic', 'vote')}{else}{__('Generic', 'votes')}{/if}.</p>
</div> </div>
</div> </div>
{/if} {/if}

View File

@ -2,12 +2,12 @@
{$best_choices = [0]} {$best_choices = [0]}
{/if} {/if}
<h3>{__('Poll results\\Votes of the poll')}</h3> <h3>{__('Poll results', 'Votes of the poll')}</h3>
<div id="tableContainer" class="tableContainer"> <div id="tableContainer" class="tableContainer">
<form action="" method="POST" id="poll_form"> <form action="" method="POST" id="poll_form">
<table class="results"> <table class="results">
<caption class="sr-only">{__('Poll results\\Votes of the poll')} {$poll->title|html}</caption> <caption class="sr-only">{__('Poll results', 'Votes of the poll')} {$poll->title|html}</caption>
<thead> <thead>
{if $admin && !$expired} {if $admin && !$expired}
<tr class="hidden-print"> <tr class="hidden-print">
@ -16,13 +16,13 @@
{foreach $slots as $slot} {foreach $slots as $slot}
{foreach $slot->moments as $id=>$moment} {foreach $slot->moments as $id=>$moment}
<td headers="M{$slot@key} D{$headersDCount} H{$headersDCount}"> <td headers="M{$slot@key} D{$headersDCount} H{$headersDCount}">
<button type="submit" name="delete_column" value="{$slot->day|html}@{$moment|html}" class="btn btn-link btn-sm" title="{__('adminstuds\\Remove the column')} {$slot->day|date_format:$date_format.txt_short|html} - {$moment|html}"><span class="glyphicon glyphicon-remove text-danger"></span><span class="sr-only">{__('Generic\\Remove')}</span></button> <button type="submit" name="delete_column" value="{$slot->day|html}@{$moment|html}" class="btn btn-link btn-sm" title="{__('adminstuds', 'Remove the column')} {$slot->day|date_format:$date_format.txt_short|html} - {$moment|html}"><span class="glyphicon glyphicon-remove text-danger"></span><span class="sr-only">{__('Generic', 'Remove')}</span></button>
</td> </td>
{$headersDCount = $headersDCount+1} {$headersDCount = $headersDCount+1}
{/foreach} {/foreach}
{/foreach} {/foreach}
<td> <td>
<button type="submit" name="add_slot" class="btn btn-link btn-sm" title="{__('adminstuds\\Add a column')}"><span class="glyphicon glyphicon-plus text-success"></span><span class="sr-only">{__('Poll results\\Add a column')}</span></button> <button type="submit" name="add_slot" class="btn btn-link btn-sm" title="{__('adminstuds', 'Add a column')}"><span class="glyphicon glyphicon-plus text-success"></span><span class="sr-only">{__('Poll results', 'Add a column')}</span></button>
</td> </td>
</tr> </tr>
{/if} {/if}
@ -86,7 +86,7 @@
<td class="bg-info" style="padding:5px"> <td class="bg-info" style="padding:5px">
<div class="input-group input-group-sm"> <div class="input-group input-group-sm">
<span class="input-group-addon"><span class="glyphicon glyphicon-user"></span></span> <span class="input-group-addon"><span class="glyphicon glyphicon-user"></span></span>
<input type="text" id="name" name="name" value="{$vote->name|html}" class="form-control" title="{__('Generic\\Your name')}" placeholder="{__('Generic\\Your name')}" /> <input type="text" id="name" name="name" value="{$vote->name|html}" class="form-control" title="{__('Generic', 'Your name')}" placeholder="{__('Generic', 'Your name')}" />
</div> </div>
</td> </td>
@ -96,26 +96,26 @@
<ul class="list-unstyled choice"> <ul class="list-unstyled choice">
<li class="yes"> <li class="yes">
<input type="radio" id="y-choice-{$k}" name="choices[{$k}]" value="2" {if $choice==2}checked {/if}/> <input type="radio" id="y-choice-{$k}" name="choices[{$k}]" value="2" {if $choice==2}checked {/if}/>
<label class="btn btn-default btn-xs" for="y-choice-{$k}" title="{__('Poll results\\Vote yes for')|html} {$slots_raw[$k]}"> <label class="btn btn-default btn-xs" for="y-choice-{$k}" title="{__('Poll results', 'Vote yes for')|html} {$slots_raw[$k]}">
<span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic\\Yes')}</span> <span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic', 'Yes')}</span>
</label> </label>
</li> </li>
<li class="ifneedbe"> <li class="ifneedbe">
<input type="radio" id="i-choice-{$k}" name="choices[{$k}]" value="1" {if $choice==1}checked {/if}/> <input type="radio" id="i-choice-{$k}" name="choices[{$k}]" value="1" {if $choice==1}checked {/if}/>
<label class="btn btn-default btn-xs" for="i-choice-{$k}" title="{__('Poll results\\Vote ifneedbe for')|html} {$slots_raw[$k]}"> <label class="btn btn-default btn-xs" for="i-choice-{$k}" title="{__('Poll results', 'Vote ifneedbe for')|html} {$slots_raw[$k]}">
(<span class="glyphicon glyphicon-ok"></span>)<span class="sr-only">{__('Generic\\Ifneedbe')}</span> (<span class="glyphicon glyphicon-ok"></span>)<span class="sr-only">{__('Generic', 'Ifneedbe')}</span>
</label> </label>
</li> </li>
<li class="no"> <li class="no">
<input type="radio" id="n-choice-{$k}" name="choices[{$k}]" value="0" {if $choice==0}checked {/if}/> <input type="radio" id="n-choice-{$k}" name="choices[{$k}]" value="0" {if $choice==0}checked {/if}/>
<label class="btn btn-default btn-xs" for="n-choice-{$k}" title="{__('Poll results\\Vote no for')|html} {$slots_raw[$k]}"> <label class="btn btn-default btn-xs" for="n-choice-{$k}" title="{__('Poll results', 'Vote no for')|html} {$slots_raw[$k]}">
<span class="glyphicon glyphicon-ban-circle"></span><span class="sr-only">{__('Generic\\No')}</span> <span class="glyphicon glyphicon-ban-circle"></span><span class="sr-only">{__('Generic', 'No')}</span>
</label> </label>
</li> </li>
</ul> </ul>
</td> </td>
{/foreach} {/foreach}
<td style="padding:5px"><button type="submit" class="btn btn-success btn-xs check-name" name="save" value="{$vote->id|html}" title="{__('Poll results\\Save the choices')} {$vote->name|html}">{__('Generic\\Save')}</button></td> <td style="padding:5px"><button type="submit" class="btn btn-success btn-xs check-name" name="save" value="{$vote->id|html}" title="{__('Poll results', 'Save the choices')} {$vote->name|html}">{__('Generic', 'Save')}</button></td>
{else} {else}
{* Voted line *} {* Voted line *}
@ -125,23 +125,23 @@
{foreach $vote->choices as $k=>$choice} {foreach $vote->choices as $k=>$choice}
{if $choice==2} {if $choice==2}
<td class="bg-success text-success" headers="M{$headersM[$k]} D{$headersD[$k]} H{$k}"><span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic\\Yes')}</span></td> <td class="bg-success text-success" headers="M{$headersM[$k]} D{$headersD[$k]} H{$k}"><span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic', 'Yes')}</span></td>
{elseif $choice==1} {elseif $choice==1}
<td class="bg-warning text-warning" headers="M{$headersM[$k]} D{$headersD[$k]} H{$k}">(<span class="glyphicon glyphicon-ok"></span>)<span class="sr-only">{__('Generic\\Ifneedbe')}</span></td> <td class="bg-warning text-warning" headers="M{$headersM[$k]} D{$headersD[$k]} H{$k}">(<span class="glyphicon glyphicon-ok"></span>)<span class="sr-only">{__('Generic', 'Ifneedbe')}</span></td>
{else} {else}
<td class="bg-danger" headers="M{$headersM[$k]} D{$headersD[$k]} H{$k}"><span class="sr-only">{__('Generic\\No')}</span></td> <td class="bg-danger" headers="M{$headersM[$k]} D{$headersD[$k]} H{$k}"><span class="sr-only">{__('Generic', 'No')}</span></td>
{/if} {/if}
{/foreach} {/foreach}
{if $active && $poll->editable && !$expired} {if $active && $poll->editable && !$expired}
<td> <td>
<button type="submit" class="btn btn-link btn-sm" name="edit_vote" value="{$vote->id|html}" title="{__('Poll results\\Edit the line:')} {$vote->name|html}"> <button type="submit" class="btn btn-link btn-sm" name="edit_vote" value="{$vote->id|html}" title="{__('Poll results', 'Edit the line:')} {$vote->name|html}">
<span class="glyphicon glyphicon-pencil"></span><span class="sr-only">{__('Generic\\Edit')}</span> <span class="glyphicon glyphicon-pencil"></span><span class="sr-only">{__('Generic', 'Edit')}</span>
</button> </button>
{if $admin} {if $admin}
<button type="submit" class="btn btn-link btn-sm" name="delete_vote" value="{$vote->id|html}" title="{__('Poll results\\Remove the line:')} {$vote->name|html}"> <button type="submit" class="btn btn-link btn-sm" name="delete_vote" value="{$vote->id|html}" title="{__('Poll results', 'Remove the line:')} {$vote->name|html}">
<span class="glyphicon glyphicon-remove text-danger"></span><span class="sr-only">{__('Generic\\Remove')}</span> <span class="glyphicon glyphicon-remove text-danger"></span><span class="sr-only">{__('Generic', 'Remove')}</span>
</button> </button>
{/if} {/if}
</td> </td>
@ -159,7 +159,7 @@
<td class="bg-info" style="padding:5px"> <td class="bg-info" style="padding:5px">
<div class="input-group input-group-sm"> <div class="input-group input-group-sm">
<span class="input-group-addon"><span class="glyphicon glyphicon-user"></span></span> <span class="input-group-addon"><span class="glyphicon glyphicon-user"></span></span>
<input type="text" id="name" name="name" class="form-control" title="{__('Generic\\Your name')}" placeholder="{__('Generic\\Your name')}" /> <input type="text" id="name" name="name" class="form-control" title="{__('Generic', 'Your name')}" placeholder="{__('Generic', 'Your name')}" />
</div> </div>
</td> </td>
{$i = 0} {$i = 0}
@ -169,20 +169,20 @@
<ul class="list-unstyled choice"> <ul class="list-unstyled choice">
<li class="yes"> <li class="yes">
<input type="radio" id="y-choice-{$i}" name="choices[{$i}]" value="2" /> <input type="radio" id="y-choice-{$i}" name="choices[{$i}]" value="2" />
<label class="btn btn-default btn-xs" for="y-choice-{$i}" title="{__('Poll results\\Vote yes for')|html} {$slot->day|date_format:$date_format.txt_short|html} - {$moment|html}"> <label class="btn btn-default btn-xs" for="y-choice-{$i}" title="{__('Poll results', 'Vote yes for')|html} {$slot->day|date_format:$date_format.txt_short|html} - {$moment|html}">
<span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic\\Yes')}</span> <span class="glyphicon glyphicon-ok"></span><span class="sr-only">{__('Generic', 'Yes')}</span>
</label> </label>
</li> </li>
<li class="ifneedbe"> <li class="ifneedbe">
<input type="radio" id="i-choice-{$i}" name="choices[{$i}]" value="1" /> <input type="radio" id="i-choice-{$i}" name="choices[{$i}]" value="1" />
<label class="btn btn-default btn-xs" for="i-choice-{$i}" title="{__('Poll results\\Vote ifneedbe for')|html} {$slot->day|date_format:$date_format.txt_short|html} - {$moment|html}"> <label class="btn btn-default btn-xs" for="i-choice-{$i}" title="{__('Poll results', 'Vote ifneedbe for')|html} {$slot->day|date_format:$date_format.txt_short|html} - {$moment|html}">
(<span class="glyphicon glyphicon-ok"></span>)<span class="sr-only">{__('Generic\\Ifneedbe')}</span> (<span class="glyphicon glyphicon-ok"></span>)<span class="sr-only">{__('Generic', 'Ifneedbe')}</span>
</label> </label>
</li> </li>
<li class="no"> <li class="no">
<input type="radio" id="n-choice-{$i}" name="choices[{$i}]" value="0" checked/> <input type="radio" id="n-choice-{$i}" name="choices[{$i}]" value="0" checked/>
<label class="btn btn-default btn-xs" for="n-choice-{$i}" title="{__('Poll results\\Vote no for')|html} {$slot->day|date_format:$date_format.txt_short|html} - {$moment|html}"> <label class="btn btn-default btn-xs" for="n-choice-{$i}" title="{__('Poll results', 'Vote no for')|html} {$slot->day|date_format:$date_format.txt_short|html} - {$moment|html}">
<span class="glyphicon glyphicon-ban-circle"></span><span class="sr-only">{__('Generic\\No')}</span> <span class="glyphicon glyphicon-ban-circle"></span><span class="sr-only">{__('Generic', 'No')}</span>
</label> </label>
</li> </li>
</ul> </ul>
@ -190,7 +190,7 @@
{$i = $i+1} {$i = $i+1}
{/foreach} {/foreach}
{/foreach} {/foreach}
<td><button type="submit" class="btn btn-success btn-md check-name" name="save" title="{__('Poll results\\Save the choices')}">{__('Generic\\Save')}</button></td> <td><button type="submit" class="btn btn-success btn-md check-name" name="save" title="{__('Poll results', 'Save the choices')}">{__('Generic', 'Save')}</button></td>
</tr> </tr>
{/if} {/if}
@ -199,7 +199,7 @@
{$max = max($best_choices)} {$max = max($best_choices)}
{if $max > 0} {if $max > 0}
<tr id="addition"> <tr id="addition">
<td>{__('Poll results\\Addition')}</td> <td>{__('Poll results', 'Addition')}</td>
{foreach $best_choices as $best_moment} {foreach $best_choices as $best_moment}
{if $max == $best_moment} {if $max == $best_moment}
{$count_bests = $count_bests +1} {$count_bests = $count_bests +1}
@ -223,13 +223,13 @@
{if $max > 0} {if $max > 0}
<div class="row"> <div class="row">
{if $count_bests == 1} {if $count_bests == 1}
<div class="col-sm-12"><h3>{__('Poll results\\Best choice')}</h3></div> <div class="col-sm-12"><h3>{__('Poll results', 'Best choice')}</h3></div>
<div class="col-sm-6 col-sm-offset-3 alert alert-success"> <div class="col-sm-6 col-sm-offset-3 alert alert-success">
<p><span class="glyphicon glyphicon-star text-warning"></span>{__('Poll results\\The best choice at this time is:')}</p> <p><span class="glyphicon glyphicon-star text-warning"></span>{__('Poll results', 'The best choice at this time is:')}</p>
{elseif $count_bests > 1} {elseif $count_bests > 1}
<div class="col-sm-12"><h3>{__('Poll results\\Best choices')}</h3></div> <div class="col-sm-12"><h3>{__('Poll results', 'Best choices')}</h3></div>
<div class="col-sm-6 col-sm-offset-3 alert alert-success"> <div class="col-sm-6 col-sm-offset-3 alert alert-success">
<p><span class="glyphicon glyphicon-star text-warning"></span>{__('Poll results\\The bests choices at this time are:')}</p> <p><span class="glyphicon glyphicon-star text-warning"></span>{__('Poll results', 'The bests choices at this time are:')}</p>
{/if} {/if}
@ -244,7 +244,7 @@
{/foreach} {/foreach}
{/foreach} {/foreach}
</ul> </ul>
<p>{__('Generic\\with')} <b>{$max|html}</b> {if $max==1}{__('Generic\\vote')}{else}{__('Generic\\votes')}{/if}.</p> <p>{__('Generic', 'with')} <b>{$max|html}</b> {if $max==1}{__('Generic', 'vote')}{else}{__('Generic', 'votes')}{/if}.</p>
</div> </div>
</div> </div>
{/if} {/if}

View File

@ -2,7 +2,7 @@
{block name=main} {block name=main}
<div class="alert alert-success text-center"> <div class="alert alert-success text-center">
<h2>{__('adminstuds\\The poll has been deleted')}</h2> <h2>{__('adminstuds', 'The poll has been deleted')}</h2>
<p>{__('Generic\\Back to the homepage of')} <a href="{$SERVER_URL|html}">{$APPLICATION_NAME|html}</a></p> <p>{__('Generic', 'Back to the homepage of')} <a href="{$SERVER_URL|html}">{$APPLICATION_NAME|html}</a></p>
</div> </div>
{/block} {/block}

View File

@ -12,7 +12,7 @@
<div class="alert alert-dismissible alert-{$message->type|html}" role="alert">{$message->message|html}<button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">&times;</span></button></div> <div class="alert alert-dismissible alert-{$message->type|html}" role="alert">{$message->message|html}<button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">&times;</span></button></div>
{/if} {/if}
</div> </div>
<div id="nameErrorMessage" class="hidden alert alert-dismissible alert-danger" role="alert">{__('PollInfo\\The name is invalid.')}<button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">&times;</span></button></div> <div id="nameErrorMessage" class="hidden alert alert-dismissible alert-danger" role="alert">{__('PollInfo', 'The name is invalid.')}<button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">&times;</span></button></div>
{* Global informations about the current poll *} {* Global informations about the current poll *}
@ -22,8 +22,8 @@
{* Information about voting *} {* Information about voting *}
{if $expired} {if $expired}
<div class="alert alert-danger"> <div class="alert alert-danger">
<p>{__('studs\\The poll is expired, it will be deleted soon.')}</p> <p>{__('studs', 'The poll is expired, it will be deleted soon.')}</p>
<p>{__('studs\\Deletion date:')} {$deletion_date|date_format:$date_format['txt_short']|html}</p> <p>{__('studs', 'Deletion date:')} {$deletion_date|date_format:$date_format['txt_short']|html}</p>
</div> </div>
{else} {else}
{if $admin} {if $admin}
@ -37,10 +37,10 @@
<div class="hidden row scroll-buttons" aria-hidden="true"> <div class="hidden row scroll-buttons" aria-hidden="true">
<div class="btn-group pull-right"> <div class="btn-group pull-right">
<button class="btn btn-sm btn-link scroll-left" title="{__('Poll results\\Scroll to the left')}"> <button class="btn btn-sm btn-link scroll-left" title="{__('Poll results', 'Scroll to the left')}">
<span class="glyphicon glyphicon-chevron-left"></span> <span class="glyphicon glyphicon-chevron-left"></span>
</button> </button>
<button class="btn btn-sm btn-link scroll-right" title="{__('Poll results\\Scroll to the right')}"> <button class="btn btn-sm btn-link scroll-right" title="{__('Poll results', 'Scroll to the right')}">
<span class="glyphicon glyphicon-chevron-right"></span> <span class="glyphicon glyphicon-chevron-right"></span>
</button> </button>
</div> </div>