diff --git a/README b/README index db33d71..643625a 100644 --- a/README +++ b/README @@ -156,14 +156,16 @@ Technologies utilisées ============================================================================= Compatibilités des navigateurs +Dernière mise à jour le 21 avril 2014 ============================================================================= -- Firefox -- Opera +- Firefox : Ubuntu 13.10/FF28 +-Chrome : Ubuntu13.10/Chromium33 +- Opera (non testé) - Konqueror -- Links -- Safari -- IE +- Links (non testé, inutile) +- Safari (non testé) +- IE : Win7/IE9 ----------------- Janvier 2008 diff --git a/admin/index.php b/admin/index.php index a926cc2..34b5b43 100644 --- a/admin/index.php +++ b/admin/index.php @@ -51,11 +51,11 @@ include_once('../bandeaux.php'); // Affichage des balises standards echo ''."\n"; -echo ''."\n"; +echo ''."\n"; echo ''."\n"; echo ''."\n"; -echo 'ADMINISTRATEUR de la base '.NOMAPPLICATION.''."\n"; -echo ''."\n"; +echo ''._("Polls administrator").' - '.NOMAPPLICATION.''."\n"; +echo ''."\n"; echo ''."\n"; echo ''."\n"; @@ -70,7 +70,7 @@ sous_bandeau_admin(); $sondage=$connect->Execute("select * from sondage"); echo'
'."\n"; -echo '
'."\n"; +echo ''."\n"; // Test et affichage du bouton de confirmation en cas de suppression de sondage while($dsondage = $sondage->FetchNextObject(false)) { if (issetAndNoEmpty('supprimersondage'.$dsondage->id_sondage) === true) { @@ -133,9 +133,9 @@ while($dsondage = $sondage->FetchNextObject(false)) { } echo ''."\n"; -echo'
'."\n"; // fin du formulaire et de la page web echo ''."\n"; +echo''."\n"; echo '
 
'; echo ''."\n"; echo ''."\n"; diff --git a/adminstuds.php b/adminstuds.php index 68ed209..ed43459 100644 --- a/adminstuds.php +++ b/adminstuds.php @@ -76,7 +76,7 @@ if (preg_match(";[\w\d]{24};i", $numsondageadmin)) { //verification de l'existence du sondage, s'il n'existe pas on met une page d'erreur if (!$sondage || $sondage->RecordCount() != 1){ - print_header(false); + print_header(false, _("Error!")); echo ''."\n"; framanav(); logo(); @@ -86,7 +86,7 @@ if (!$sondage || $sondage->RecordCount() != 1){ echo '
'."\n"; print "

" . _("This poll doesn't exist !") . "



"."\n"; - print "" . _("Back to the homepage of ") . " ".NOMAPPLICATION.". "."\n"; + print "" . _("Back to the homepage of ") . " ".NOMAPPLICATION.". "."\n"; echo '



'."\n"; echo '
'."\n"; # sur_bandeau_pied(); @@ -324,7 +324,7 @@ if (isset($_POST["confirmesuppression"]) || isset($_POST["confirmesuppression_x" echo '
'."\n"; print "

" . _("Your poll has been removed!") . "



"; - print _("Back to the homepage of ") . ' '.NOMAPPLICATION.'.'."\n"; + print _("Back to the homepage of ") . ' '.NOMAPPLICATION.'.'."\n"; echo '


'."\n"; echo '
'."\n"; sur_bandeau_pied(); @@ -726,7 +726,7 @@ if ($sondage !== false) { $sql = $connect->Prepare($sql); $user_studs = $connect->Execute($sql, array($numsondage)); } else { - print_header(false); + print_header(false, _("Error!")); echo ''."\n"; framanav(); logo(); @@ -734,7 +734,7 @@ if ($sondage !== false) { bandeau_titre(_("Error!")); echo '
'."\n"; print "

" . _("This poll doesn't exist !") . "



"."\n"; - print "" . _("Back to the homepage of ") . " ".NOMAPPLICATION.". "."\n"; + print "" . _("Back to the homepage of ") . " ".NOMAPPLICATION.". "."\n"; echo '



'."\n"; echo '
'."\n"; @@ -756,7 +756,7 @@ $nbcolonnes=substr_count($dsujet->sujet,',')+1; echo '
'."\n"; echo '
'."\n"; -echo _('As poll administrator, you can change all the lines of this poll with infos.
You can, as well, remove a column or a line with Cancel.
You can also add a new column with Add column.
Finally, you can change the informations of this poll like the title, the comments or your email address.') ."\n"; +echo _('As poll administrator, you can change all the lines of this poll with infos.
You can, as well, remove a column or a line with Cancel.
You can also add a new column with Add column.
Finally, you can change the informations of this poll like the title, the comments or your email address.') ."\n"; echo '

'."\n"; //debut de l'affichage de résultats @@ -767,10 +767,11 @@ $toutsujet=explode(",",$dsujet->sujet); echo ''."\n"; echo ''."\n"; echo ''."\n"; +echo ''."\n"; //boucle pour l'affichage des boutons de suppression de colonne for ($i = 0; isset($toutsujet[$i]); $i++) { - echo ''."\n"; + echo ''."\n"; } echo ''."\n"; @@ -806,7 +807,7 @@ if ($dsondage->format=="D"||$dsondage->format=="D+") { } } - echo ''."\n"; + echo ''."\n"; echo ''."\n"; echo ''."\n"; echo ''."\n"; @@ -840,7 +841,7 @@ if ($dsondage->format=="D"||$dsondage->format=="D+") { } } - echo ''."\n"; + echo ''."\n"; echo ''."\n"; echo ''."\n"; echo ''."\n"; @@ -874,7 +875,7 @@ if ($dsondage->format=="D"||$dsondage->format=="D+") { } } - echo ''."\n"; + echo ''."\n"; echo ''."\n"; //affichage des horaires @@ -892,7 +893,7 @@ if ($dsondage->format=="D"||$dsondage->format=="D+") { } } - echo ''."\n"; + echo ''."\n"; echo ''."\n"; } } else { @@ -907,7 +908,7 @@ if ($dsondage->format=="D"||$dsondage->format=="D+") { echo ''.stripslashes($toutsujet[$i]).''."\n"; } - echo ''."\n"; + echo ''."\n"; echo ''."\n"; } @@ -920,7 +921,7 @@ while ($data = $user_studs->FetchNextObject(false)) { $ensemblereponses = $data->reponses; echo ''."\n"; - echo ''."\n"; + echo ''."\n"; //affichage du nom $nombase=str_replace("°","'",$data->nom); @@ -971,14 +972,14 @@ while ($data = $user_studs->FetchNextObject(false)) { //a la fin de chaque ligne se trouve les boutons modifier if (!$testligneamodifier=="true") { - echo ''."\n"; + echo ''."\n"; } //demande de confirmation pour modification de ligne for ($i = 0; $i < $nblignes; $i++) { if (isset($_POST["modifierligne$i"]) || isset($_POST['modifierligne'.$i.'_x'])) { if ($compteur == $i) { - echo ''."\n"; + echo ''."\n"; } } } @@ -1001,7 +1002,7 @@ for ($i = 0; $i < $nbcolonnes; $i++) { } // Affichage du bouton de formulaire pour inscrire un nouvel utilisateur dans la base -echo ''."\n"; +echo ''."\n"; echo ''."\n"; //determination du meilleur choix @@ -1040,19 +1041,20 @@ for ($i = 0; $i < $nbcolonnes; $i++) { echo ''.$affichesomme.''."\n"; } } - +echo ''."\n"; +echo ''."\n"; echo ''."\n"; echo ''."\n"; echo ''."\n"; for ($i = 0; $i < $nbcolonnes; $i++) { if (isset($somme[$i]) === true && isset($meilleurecolonne) === true && $somme[$i] == $meilleurecolonne){ - echo 'Meilleur resultat'."\n"; + echo 'Meilleur resultat'."\n"; } else { echo ''."\n"; } } - +echo ''."\n"; echo ''."\n"; @@ -1139,9 +1141,9 @@ echo '

'."\n"; //affichage de la phrase annoncant le meilleur sujet if (isset($meilleurecolonne) && $compteursujet == "1") { - print "\"Meilleur" . _("The best choice at this time is") . " : $meilleursujet " . _("with") . " $meilleurecolonne " . $vote_str . ".
\n"; + print "\"Meilleur" . _("The best choice at this time is") . " : $meilleursujet " . _("with") . " $meilleurecolonne " . $vote_str . ".
\n"; } elseif (isset($meilleurecolonne)) { - print "\"Meilleur " . _("The bests choices at this time are") . " : $meilleursujet " . _("with") . " $meilleurecolonne " . $vote_str . ".
\n"; + print "\"Meilleur " . _("The bests choices at this time are") . " : $meilleursujet " . _("with") . " $meilleurecolonne " . $vote_str . ".
\n"; } echo '

'."\n"; @@ -1158,7 +1160,7 @@ echo '
'."\n"; $adresseadmin=$dsondage->mail_admin; echo _("Change the title") .' :
' . ''. - '

'."\n"; + '

'."\n"; //si la valeur du nouveau titre est invalide : message d'erreur if ((isset($_POST["boutonnouveautitre"]) || isset($_POST["boutonnouveautitre_x"])) && !issetAndNoEmpty('nouveautitre')) { @@ -1166,10 +1168,10 @@ if ((isset($_POST["boutonnouveautitre"]) || isset($_POST["boutonnouveautitre_x"] } //Changer les commentaires du sondage -echo _("Change the comments") .' :



'."\n"; +echo _("Change the comments") .' :



'."\n"; //Changer l'adresse de l'administrateur -echo _("Change your email address") .' :

'."\n"; +echo _("Change your email address") .' :

'."\n"; //si l'adresse est invalide ou le champ vide : message d'erreur if ((isset($_POST["boutonnouvelleadresse"]) || isset($_POST["boutonnouvelleadresse_x"])) && !issetAndNoEmpty('nouvelleadresse')) { @@ -1185,7 +1187,7 @@ if ($comment_user->RecordCount() != 0) { $i = 0; while ( $dcomment=$comment_user->FetchNextObject(false)) { - print " ". stripslashes($dcomment->usercomment) ." : ".stripslashes($dcomment->comment) ."
"; + print " ". stripslashes($dcomment->usercomment) ." : ".stripslashes($dcomment->comment) ."
"; $i++; } @@ -1200,21 +1202,21 @@ if (isset($erreur_commentaire_vide) && $erreur_commentaire_vide=="yes") { print "
" . _("Add a comment in the poll") . " :
\n"; echo _("Name") .' :
'."\n"; echo ''."\n"; -echo '
'."\n"; +echo '
'."\n"; //suppression du sondage echo '
'."\n"; -echo _("Remove your poll") .' :

'."\n"; +echo _("Remove your poll") .' :

'."\n"; echo '

'."\n"; if ($dsondage->format == "D" || $dsondage->format == "D+") { - echo '
'."\n"; + echo ''."\n"; echo _("Generate the convocation letter (.PDF), choose the place to meet and validate") .'
'; echo ''; echo ''; echo ''; - echo '

'; + echo '

'; echo '
'."\n"; // ''. _("Enter a meeting place!") .'

'."\n"; } @@ -1224,14 +1226,14 @@ if (isset($_POST["exportpdf_x"]) && !issetAndNoEmpty('lieureunion')) { echo ''. _("Enter a meeting place!") .'

'."\n"; } -echo ''."\n"; +echo ''."\n"; echo '

'."\n"; //fin de la partie GESTION et beandeau de pied -echo '

'."\n"; +//echo '

'."\n"; echo '
'; echo '
 
'; bandeau_pied_mobile(); -echo ''."\n"; +//echo ''."\n"; echo ''."\n"; echo ''."\n"; diff --git a/apropos.php b/apropos.php index aa6d44d..0a97166 100644 --- a/apropos.php +++ b/apropos.php @@ -49,10 +49,10 @@ if (file_exists('bandeaux_local.php')) { //affichage de la page echo ''."\n"; -echo ''."\n"; +echo ''."\n"; echo ''."\n"; echo ''."\n"; -echo ''.NOMAPPLICATION.''."\n"; +echo ''._("About").' - '.NOMAPPLICATION.''."\n"; echo ''."\n"; echo ''."\n"; echo ''."\n"; @@ -319,4 +319,4 @@ echo ''."\n"; bandeau_pied_mobile(); echo ''."\n"; echo ''."\n"; -echo ''."\n"; \ No newline at end of file +echo ''."\n"; diff --git a/bandeaux.php b/bandeaux.php index 0f6cbaf..833460a 100644 --- a/bandeaux.php +++ b/bandeaux.php @@ -41,13 +41,11 @@ include_once('fonctions.php'); function framanav() { -/* if (file_exists($_SERVER['DOCUMENT_ROOT']."/framanav/nav.php")) { - //echo "\n".' '."\n";; - //echo ''."\n"; - include_once($_SERVER['DOCUMENT_ROOT']."/framanav/nav.php"); - //echo ' '."\n"; - }*/ + if (file_exists($_SERVER['DOCUMENT_ROOT']."/nav/nav.js")) { + echo "\n".' '."\n";; echo ''."\n"; + echo ' '."\n"; + } } function gAnalytics() { @@ -73,7 +71,7 @@ function gAnalytics() { function logo () { /* if(defined('LOGOBANDEAU')) { - echo ''."\n"; + echo ''."\n"; }*/ } @@ -83,11 +81,11 @@ function bandeau_tete() { if ( IMAGE_TITRE ) { - echo '
'.NOMAPPLICATION.'
'."\n"; + echo ''."\n"; } else { - echo '
'.NOMAPPLICATION.'
'."\n"; + echo ''."\n"; } ; @@ -97,7 +95,7 @@ function bandeau_tete() // bandeaux de titre function bandeau_titre($titre) { - echo '
'. $titre .'
'."\n"; + echo '

'. $titre .'

'."\n"; } @@ -107,7 +105,7 @@ function liste_lang() $str = ''; foreach ($ALLOWED_LANGUAGES as $k => $v ) { - $str .= '' . $v . '' . "\n" ; + $str .= '
  • ' . $v . '
  • ' . "\n" ; } return $str; @@ -118,7 +116,7 @@ function liste_lang() function sous_bandeau() { /*echo '
    ' . - ''. _("Home") .'' . + ''. _("Home") .'' . ''. _("Example") .'' . ''. _("Contact") .'' . //''. _("Sources") .'' . //not implemented @@ -133,15 +131,15 @@ function sous_bandeau() function sous_bandeau_admin() { echo '
    ' . - ''. _("Home") .''; + ''. _("Home") .''; if(is_readable('logs_studs.txt')) { - echo ''. _("Logs") .''; + echo ''. _("Logs") .''; } - echo ''. _("Cleaning") .'' . - '' . - liste_lang() . ''. + echo ''. _("Cleaning") .'' . + ''. '
    '."\n"; gAnalytics(); @@ -166,16 +164,17 @@ function sur_bandeau_pied() function bandeau_pied() { //echo '
    '. _("Université de Strasbourg. Creation: Guilhem BORGHESI. 2008-2009") .'
    '."\n"; - echo '
     
    '; echo '
    ' . - ''. _("Home") .'' . - ''. _("Example") .'' . - ''. _("Contact") .'' . + '' . + ''. '
    ' . "\n"; gAnalytics(); } @@ -187,14 +186,16 @@ function bandeau_pied_mobile() '
    '. _("Université de Strasbourg. Creation: Guilhem BORGHESI. 2008-2009") .'
    '."\n";*/ echo '
     
    '; echo '
    ' . - ''. _("Home") .'' . - ''. _("Example") .'' . - ''. _("Contact") .'' . + '' . + ''. '
    ' . "\n"; gAnalytics(); } diff --git a/buttons.css b/buttons.css index 1090579..13acce3 100644 --- a/buttons.css +++ b/buttons.css @@ -71,9 +71,9 @@ .gray { color: #e9e9e9; border: solid 1px #555; - background: #6e6e6e; - background: -webkit-gradient(linear, left top, left bottom, from(#888), to(#575757)); - background: -moz-linear-gradient(top, #888, #575757); + background-color: #575757; + background-image: -webkit-gradient(linear, left top, left bottom, from(#888), to(#575757)); + background-image: -moz-linear-gradient(top, #888, #575757); filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#888888', endColorstr='#575757'); } .gray:hover { @@ -114,11 +114,11 @@ /* orange */ .orange { color: #fef4e9; - border: solid 1px #da7c0c; - background: #f78d1d; - background: -webkit-gradient(linear, left top, left bottom, from(#faa51a), to(#f47a20)); - background: -moz-linear-gradient(top, #faa51a, #f47a20); - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#faa51a', endColorstr='#f47a20'); + border: solid 1px #c42710; + background-color: #c42710; + background-image: -webkit-gradient(linear, left top, left bottom, from(#f47a20), to(#c42710)); + background-image: -moz-linear-gradient(top, #f47a20, #c42710); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#f47a20', endColorstr='#c42710'); } .orange:hover { background: #f47c20; @@ -158,11 +158,11 @@ /* blue */ .blue { color: #d9eef7; - border: solid 1px #0076a3; - background: #0095cd; - background: -webkit-gradient(linear, left top, left bottom, from(#00adee), to(#0078a5)); - background: -moz-linear-gradient(top, #00adee, #0078a5); - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#00adee', endColorstr='#0078a5'); + border: solid 1px #00328B; + background-color: #00328B; + background-image: -webkit-gradient(linear, left top, left bottom, from(#0078a5), to(#00328B)); + background-image: -moz-linear-gradient(top, #0078a5, #00328B); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#0078a5', endColorstr='#00328B'); } .blue:hover { background: #007ead; @@ -203,21 +203,21 @@ .green { color: #e8f0de; border: solid 1px #538312; - background: #64991e; - background: -webkit-gradient(linear, left top, left bottom, from(#7db72f), to(#4e7d0e)); - background: -moz-linear-gradient(top, #7db72f, #4e7d0e); - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#7db72f', endColorstr='#4e7d0e'); + background-color: #426514; + background-image: -webkit-gradient(linear, left top, left bottom, from(#4e7d0e), to(#426514)); + background-image: -moz-linear-gradient(top, #7db72f, #4e7d0e); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#4e7d0e', endColorstr='#426514'); } .green:hover { - background: #538018; - background: -webkit-gradient(linear, left top, left bottom, from(#6b9d28), to(#436b0c)); - background: -moz-linear-gradient(top, #6b9d28, #436b0c); + background-color: #538018; + background-image: -webkit-gradient(linear, left top, left bottom, from(#6b9d28), to(#436b0c)); + background-image: -moz-linear-gradient(top, #6b9d28, #436b0c); filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#6b9d28', endColorstr='#436b0c'); } .green:active { color: #a9c08c; - background: -webkit-gradient(linear, left top, left bottom, from(#4e7d0e), to(#7db72f)); - background: -moz-linear-gradient(top, #4e7d0e, #7db72f); + background-image: -webkit-gradient(linear, left top, left bottom, from(#4e7d0e), to(#7db72f)); + background-image: -moz-linear-gradient(top, #4e7d0e, #7db72f); filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#4e7d0e', endColorstr='#7db72f'); } diff --git a/choix_autre.php b/choix_autre.php index b44441c..c0a6e21 100644 --- a/choix_autre.php +++ b/choix_autre.php @@ -48,22 +48,21 @@ if (file_exists('bandeaux_local.php')) { //si les variables de session ne sont pas valides, il y a une erreur if (issetAndNoEmpty('titre', $_SESSION) === false || issetAndNoEmpty('nom', $_SESSION) === false || issetAndNoEmpty('adresse', $_SESSION) === false) { - echo ''."\n"; - echo ''."\n"; + echo ''."\n"; + echo ''."\n"; echo ''."\n"; - echo ''."\n"; - echo ''.NOMAPPLICATION.''."\n"; - echo ''."\n"; + echo ''."\n"; + echo ''._("Error!").' - '.NOMAPPLICATION.''."\n"; + echo ''."\n"; echo ''."\n"; echo ''."\n"; framanav(); logo(); bandeau_tete(); bandeau_titre(_("Error!")); - echo '
    '."\n"; - print "

    " . _("You haven't filled the first section of the poll creation.") . " !

    "."\n"; - print "" . _("Back to the homepage of ") . " ".NOMAPPLICATION."."."\n"; - echo '


    '."\n"; + echo '
    '."\n"; + print "

    " . _("You haven't filled the first section of the poll creation.") . " !

    "."\n"; + print "" . _("Back to the homepage of ") . " ".NOMAPPLICATION."."."\n"; echo '
    '."\n"; //bandeau de pied bandeau_pied(); @@ -136,7 +135,14 @@ if (issetAndNoEmpty('titre', $_SESSION) === false || issetAndNoEmpty('nom', $_SE $_SESSION["nbrecases"]=$_SESSION["nbrecases"]+5; } - print_header(); + + if( ($testremplissage != "ok" && (isset($_POST["fin_sondage_autre"]) || isset($_POST["fin_sondage_autre_x"]))) || ($testdate === false) || ($erreur_injection) ) { + // S'il y a des erreurs + print_header(false, _("Error!") .' - '. _("Poll subjects (2 on 2)")); + } else { + print_header(false, _("Poll subjects (2 on 2)")); + } + echo ''."\n"; framanav(); @@ -146,8 +152,8 @@ if (issetAndNoEmpty('titre', $_SESSION) === false || issetAndNoEmpty('nom', $_SE bandeau_titre(_("Poll subjects (2 on 2)")); sous_bandeau_choix(); - echo '
    '."\n"; - echo '
    '. _("Your poll aim is to make a choice between different subjects.
    Enter the subjects to vote for:") .'

    '."\n"; + echo '
    '."\n"; + echo '

    '. _("Your poll aim is to make a choice between different subjects.
    Enter the subjects to vote for:") .'

    '."\n"; echo ''."\n"; //affichage des cases texte de formulaire @@ -156,7 +162,7 @@ if (issetAndNoEmpty('titre', $_SESSION) === false || issetAndNoEmpty('nom', $_SE if (isset($_SESSION["choix$i"]) === false) { $_SESSION["choix$i"] = ''; } - echo ''."\n"; + echo ''."\n"; } echo '
    '. _("Choice") .' '.$j.' :
    :
    '."\n"; @@ -168,9 +174,8 @@ if (issetAndNoEmpty('titre', $_SESSION) === false || issetAndNoEmpty('nom', $_SE //ajout de cases supplementaires echo ''."\n"; - echo ''."\n"; + echo ''."\n"; echo '
    '. _("5 choices more") .''. _("5 choices more") .'
    '."\n"; - echo'
    '."\n"; //echo ''."\n"; //echo ''."\n"; @@ -191,46 +196,43 @@ if (!isset($_POST["fin_sondage_autre_x"])) { //message d'erreur si aucun champ renseigné if ($testremplissage != "ok" && (isset($_POST["fin_sondage_autre"]) || isset($_POST["fin_sondage_autre_x"]))) { - print "
    " . _("Enter at least one choice") . "

    "."\n"; + print "

    " . _("Enter at least one choice") . "

    "."\n"; $erreur = true; } //message d'erreur si mauvaise date if ($testdate === false) { - print "
    " . _("Date must be have the format DD/MM/YYYY") . "

    "."\n"; + print "

    " . _("Date must be have the format DD/MM/YYYY") . "

    "."\n"; } if ($erreur_injection) { - print "" . _("Characters \" < and > are not permitted") . "

    \n"; + print "

    " . _("Characters \" < and > are not permitted") . "

    \n"; } if ((isset($_POST["fin_sondage_autre"]) || isset($_POST["fin_sondage_autre_x"])) && !$erreur && !$erreur_injection) { //demande de la date de fin du sondage - echo '
    '."\n"; echo '
    '."\n"; - echo '
    '. _("Your poll will be automatically removed after 6 months.
    You can fix another removal date for it.") .'

    '."\n"; - echo _("Removal date (optional)") .' : '. _("(DD/MM/YYYY)") ."\n"; + echo '

    '. _("Your poll will be automatically removed after 6 months.
    You can fix another removal date for it.") .'

    '."\n"; + echo ' : '. _("(DD/MM/YYYY)") .''."\n"; echo '
    '."\n"; echo '
    '."\n"; - echo ''. _("Once you have confirmed the creation of your poll, you will be automatically redirected on the page of your poll.

    Then, you will receive quickly an email contening the link to your poll for sending it to the voters.") .'
    '."\n"; + echo '

    '. _("Once you have confirmed the creation of your poll, you will be automatically redirected on the page of your poll.

    Then, you will receive quickly an email contening the link to your poll for sending it to the voters.").'

    '."\n"; echo '
    '."\n"; - echo '
    '."\n"; //echo '
    '. _("Next") .'
    '."\n"; //echo ''."\n"; //echo '
    '. _("Create the poll") .'
    '."\n"; - echo ''; + echo ''; echo '
    '; } //fin du formulaire et bandeau de pied echo ''."\n"; - echo ''."\n"; - echo '


    '."\n"; + echo ''."\n"; echo '
    '."\n"; //bandeau de pied bandeau_pied_mobile(); echo ''."\n"; echo ''."\n"; -} \ No newline at end of file +} diff --git a/choix_date.php b/choix_date.php index ff1ae04..6126d15 100644 --- a/choix_date.php +++ b/choix_date.php @@ -50,11 +50,11 @@ if (is_readable('bandeaux_local.php')) { //si les variables de session ne snot pas valides, il y a une erreur if (!issetAndNoEmpty('nom', $_SESSION) && !issetAndNoEmpty('adresse', $_SESSION) && !issetAndNoEmpty('commentaires', $_SESSION) && !issetAndNoEmpty('mail', $_SESSION)) { echo ''."\n"; - echo ''."\n"; + echo ''."\n"; echo ''."\n"; echo ''."\n"; - echo ''.NOMAPPLICATION.''."\n"; - echo ''."\n"; + echo ''._("Error!").' - '.NOMAPPLICATION.''."\n"; + echo ''."\n"; echo ''."\n"; echo ''."\n"; framanav(); @@ -63,7 +63,7 @@ if (!issetAndNoEmpty('nom', $_SESSION) && !issetAndNoEmpty('adresse', $_SESSION) bandeau_titre(_("Error!")); echo '
    '."\n"; print "

    " . _("You haven't filled the first section of the poll creation.") . " !

    "."\n"; - print _("Back to the homepage of ") . ' ' . '' . NOMAPPLICATION . '.' . "\n"; + print _("Back to the homepage of ") . ' ' . '' . NOMAPPLICATION . '.' . "\n"; echo '


    '."\n"; echo '
    '."\n"; //bandeau de pied @@ -214,12 +214,12 @@ if (!issetAndNoEmpty('nom', $_SESSION) && !issetAndNoEmpty('adresse', $_SESSION) //debut de la page web echo ''."\n"; - echo ''."\n"; + echo ''."\n"; echo ''."\n"; echo ''."\n"; - echo ''.NOMAPPLICATION.''."\n"; - echo ''."\n"; - echo ''; + echo ''._("Poll dates (2 on 2)").' - '.NOMAPPLICATION.''."\n"; + echo ''."\n"; + echo ''; echo ''."\n"; echo ''."\n"; @@ -230,7 +230,7 @@ if (!issetAndNoEmpty('nom', $_SESSION) && !issetAndNoEmpty('adresse', $_SESSION) bandeau_titre(_("Poll dates (2 on 2)")); sous_bandeau_choix(); - echo '
    '."\n"; + echo ''."\n"; //ajout pyg pour la cohérence graphique @@ -244,7 +244,7 @@ if (!issetAndNoEmpty('nom', $_SESSION) && !issetAndNoEmpty('adresse', $_SESSION) //debut du tableau qui affiche le calendrier echo '
    '."\n"; echo ''."\n"; - echo ''."\n"; + echo ''."\n"; echo '
    '.$motmois.' '.$_SESSION["annee"].'
    '.$motmois.' '.$_SESSION["annee"].'
    '."\n"; echo ''."\n"; echo ''."\n"; @@ -498,7 +498,7 @@ if (!issetAndNoEmpty('nom', $_SESSION) && !issetAndNoEmpty('adresse', $_SESSION) } if ($_SESSION["nbrecaseshoraires"] < 10) { - echo ''."\n"; + echo ''."\n"; } echo ''."\n"; @@ -621,4 +621,4 @@ if (!issetAndNoEmpty('nom', $_SESSION) && !issetAndNoEmpty('adresse', $_SESSION) unset($_SESSION["nbrecaseshoraires"]); echo ''; } -} \ No newline at end of file +} diff --git a/contacts.php b/contacts.php index d1d72c4..2590fd6 100644 --- a/contacts.php +++ b/contacts.php @@ -65,21 +65,20 @@ if ((isset($_POST['envoiquestion']) || isset($_POST['envoiquestion_x'])) && isse } //affichage de la page de confirmation d'envoi - echo ''."\n"; - echo ''."\n"; + echo ''."\n"; + echo ''."\n"; echo ''."\n"; - echo ''.NOMAPPLICATION.''."\n"; + echo ''._("Make your polls").' - '.NOMAPPLICATION.''."\n"; echo ''."\n"; - echo ''."\n"; + echo ''."\n"; echo ''."\n"; echo ''."\n"; logo(); bandeau_tete(); bandeau_titre(_("Make your polls")); echo '
    '."\n"; - print "

    " . _("Your message has been sent!") . "



    "."\n"; - print "" . _("Back to the homepage of ") . " ".NOMAPPLICATION."."."\n"; - echo '


    '."\n"; + print "

    " . _("Your message has been sent!") . "

    "."\n"; + print "" . _("Back to the homepage of ") . " ".NOMAPPLICATION."."."\n"; echo '
    '."\n"; bandeau_pied(); session_unset(); @@ -94,19 +93,19 @@ if ((isset($_POST['envoiquestion']) || isset($_POST['envoiquestion_x'])) && isse } //affichage de la page - echo ''."\n"; - echo ''."\n"; + echo ''."\n"; + echo ''."\n"; echo ''."\n"; echo ''."\n"; - echo ''.NOMAPPLICATION.''."\n"; - echo ''."\n"; + echo ''._("Contact us").' - '.NOMAPPLICATION.''."\n"; + echo ''."\n"; echo ''."\n"; echo ''."\n"; framanav(); //debut du formulaire - echo ''."\n"; + echo ''."\n"; //bandeaux de tete logo(); @@ -132,8 +131,6 @@ framanav(); echo ' '. _("The address is not correct!") .''; } - echo '

    '; - echo _("Question") .' :
    '."\n"; echo ''; @@ -141,9 +138,7 @@ framanav(); echo '  Il faut poser une question !'; } - echo '


    '."\n"; echo ''; - echo '


    '."\n"; echo ''."\n"; echo ''."\n"; //bandeau de pied diff --git a/errors/error-forbidden.php b/errors/error-forbidden.php index c0c6e74..d4af9b8 100644 --- a/errors/error-forbidden.php +++ b/errors/error-forbidden.php @@ -41,7 +41,7 @@ include '../bandeaux.php'; echo ''."\n"; -echo ''."\n"; +echo ''."\n"; echo ''."\n"; echo ''."\n"; echo 'Erreur !'."\n"; @@ -62,4 +62,4 @@ echo ''."\n"; sur_bandeau_pied(); bandeau_pied(); echo ''."\n"; -echo ''."\n"; \ No newline at end of file +echo ''."\n"; diff --git a/fonctions.php b/fonctions.php index 92837d3..9f7513b 100644 --- a/fonctions.php +++ b/fonctions.php @@ -56,7 +56,7 @@ function connexion_base() function get_server_name() { $scheme = (isset($_SERVER["HTTPS"]) && $_SERVER["HTTPS"] == 'on') ? 'https' : 'http'; - return $scheme . '://' . $_SERVER['SERVER_NAME'] . '/'; + return $scheme . '://' . $_SERVER['SERVER_NAME'] . dirname($_SERVER['SCRIPT_NAME']).'/'; } @@ -105,10 +105,10 @@ function is_user() function print_header($js = false, $nom_sondage = '') { - echo ' - + echo ' + - '; + '; if (empty($nom_sondage) === false) { echo ' '.stripslashes($nom_sondage).' - '.NOMAPPLICATION.''; @@ -117,8 +117,8 @@ function print_header($js = false, $nom_sondage = '') '.NOMAPPLICATION.''; } echo ' - - '; + + '; echo ''; } @@ -219,15 +219,15 @@ function getUrlSondage($id, $admin = false) { if (URL_PROPRE === true) { if ($admin === true) { - $url = get_server_name().$id.'/admin'; + $url = str_replace('/admin','',get_server_name()).$id.'/admin'; } else { - $url = get_server_name().$id; + $url = str_replace('/admin','',get_server_name()).$id; } } else { if ($admin === true) { - $url = get_server_name().'adminstuds.php?sondage='.$id; + $url = str_replace('/admin','',get_server_name()).'adminstuds.php?sondage='.$id; } else { - $url = get_server_name().'studs.php?sondage='.$id; + $url = str_replace('/admin','',get_server_name()).'studs.php?sondage='.$id; } } diff --git a/framanav b/framanav deleted file mode 160000 index 24d503e..0000000 --- a/framanav +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 24d503e3e56e9fa095a2cee17576f6f0cb518fcc diff --git a/i18n.php b/i18n.php index 439fee7..34c20c7 100644 --- a/i18n.php +++ b/i18n.php @@ -23,3 +23,7 @@ textdomain($domain); /* temp, for compatibility :*/ $a = explode('_', $locale); $_SESSION['langue'] = strtoupper($a[0]); + +/* */ +$lang = ($_SESSION['langue']!='') ? strtolower($_SESSION['langue']) : 'fr'; + diff --git a/index.php b/index.php index e574c90..b1ef0e7 100644 --- a/index.php +++ b/index.php @@ -47,12 +47,12 @@ if (is_readable('bandeaux_local.php')) { session_start(); //affichage de la page -echo ''."\n"; -echo ''."\n"; +echo ''."\n"; +echo ''."\n"; echo ''."\n"; echo ''."\n"; -echo ''.NOMAPPLICATION.''."\n"; -echo ''."\n"; +echo ''._("Home").' - '.NOMAPPLICATION.''."\n"; +echo ''."\n"; echo ''."\n"; echo ''."\n"; @@ -73,17 +73,15 @@ echo '
    '."\n"; # ''; #echo '
    ' . "\n"; -echo '
    '."\n"; - echo ''; echo '
    '; -echo '
    '; -echo ''. _('Make a poll') . ''; +echo '

    '; +echo ''. _('Make a poll') . '

    '; echo '
    '; diff --git a/infos_sondage.php b/infos_sondage.php index e7b8482..473074d 100644 --- a/infos_sondage.php +++ b/infos_sondage.php @@ -141,18 +141,23 @@ if (issetAndNoEmpty("poursuivre")){ } + } else { + // Title Erreur ! + print_header(true, _("Error!").' - '._("Poll creation (1 on 2)")); } +} else { + // Title OK (formulaire pas encore rempli) + print_header(true, _("Poll creation (1 on 2)")); } //affichage de la page -print_header(true); echo ''."\n"; framanav(); //affichage des bandeaux de tete logo(); bandeau_tete(); -echo '
    '. _("Poll creation (1 on 2)") .'
    '."\n"; +echo '

    '. _("Poll creation (1 on 2)") .'

    '."\n"; sous_bandeau(); // premier sondage ? test l'existence des schémas SQL avant d'aller plus loin @@ -167,56 +172,69 @@ if(!check_table_sondage()) { } //debut du formulaire -echo ''."\n"; +echo ''."\n"; -echo '
    '."\n"; -echo '
    '. _("You are in the poll creation section.
    Required fields cannot be left blank") .'

    '."\n"; +echo '
    '."\n"; +echo '

    '. _("You are in the poll creation section.
    Required fields cannot be left blank") .'

    '."\n"; //Affichage des différents champs textes a remplir -echo '
    '."\n"; +echo '
    '."\n"; -echo ''."\n"; +echo '"."\n"; + // fermeture de la ligne du dessus avec attribut aria-describeby pour avoir les infos concernant l'erreur + // pas très propre mais bon... + echo 'aria-describeby="#poll_title_error">'."\n"; + echo ''."\n"; } elseif ($erreur_injection_titre) { - print "
    "."\n"; + // idem + echo 'aria-describeby="#poll_title_error">'."\n"; + echo ''."\n"; +} else { + // pas d'erreur, pas d'aria + echo '>'."\n"; } echo ''."\n"; -echo ''."\n"; +echo ''."\n"; + echo '"."\n"; +} else { + // pas d'erreur, pas d'aria + echo '>'.stripslashes($_SESSION["commentaires"]).''."\n"; } echo ''."\n"; -echo ''."\n"; } else { - echo ''."\n"; + echo ''."\n"; } if (!$_SESSION["nom"] && issetAndNoEmpty("poursuivre")) { - print ""."\n"; + print ""."\n"; } elseif ($erreur_injection_nom) { - print "
    "."\n"; + print ""."\n"; } echo ''."\n"; -echo ''."\n"; } else { - echo ''."\n"; + echo ''."\n"; } if (!$_SESSION["adresse"] && issetAndNoEmpty("poursuivre")) { - print ""."\n"; + print ""."\n"; } elseif ($erreur_adresse && issetAndNoEmpty("poursuivre")) { - print ""."\n"; + print ""."\n"; } echo ''."\n"; @@ -238,13 +256,13 @@ if ($_SESSION["studsplus"]=="+") { $cocheplus="checked"; } -echo '
    '."\n"; +echo '

    '."\n"; if ($_SESSION["mailsonde"]) { $cochemail="checked"; } -echo '
    '."\n"; +echo '

    '."\n"; //affichage des boutons pour choisir sondage date ou autre if ($_GET['choix_sondage'] == 'date') { @@ -253,7 +271,7 @@ if ($_GET['choix_sondage'] == 'date') { $choix = "creation_sondage_autre"; } echo ''; -echo '
    '; +echo ''; echo '
    '; diff --git a/locale/de_DE/LC_MESSAGES/Studs.mo b/locale/de_DE/LC_MESSAGES/Studs.mo index 87e4b0a..caf6a9f 100644 Binary files a/locale/de_DE/LC_MESSAGES/Studs.mo and b/locale/de_DE/LC_MESSAGES/Studs.mo differ diff --git a/locale/de_DE/LC_MESSAGES/Studs.po b/locale/de_DE/LC_MESSAGES/Studs.po index fe3da6b..ae12615 100644 --- a/locale/de_DE/LC_MESSAGES/Studs.po +++ b/locale/de_DE/LC_MESSAGES/Studs.po @@ -400,8 +400,8 @@ msgid "Comments" msgstr "Kommentar" #: studs.php:261 -msgid "If you want to vote in this poll, you have to give your name, choose the values that fit best for you
    (without paying attention to the choices of the other voters) and validate with the plus button at the end of the line." -msgstr "Um an dieser Umfrage Teilzunehmen tragen sie bitte ihren Namen, wählen sie die ihnen passenden Wehrte (ohne die dispo der anderen Teilnehmer zu beachten)
    und bestätigen sie ihre Wahl mit dem Knopf am ende der Ligne." +msgid "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." +msgstr "Um an dieser Umfrage Teilzunehmen tragen sie bitte ihren Namen, wählen sie die ihnen passenden Wehrte
    und bestätigen sie ihre Wahl mit dem Knopf am ende der Ligne." #: studs.php:445 #: adminstuds.php:806 diff --git a/locale/en_GB/LC_MESSAGES/Studs.mo b/locale/en_GB/LC_MESSAGES/Studs.mo index ec3d9c4..43e14ec 100644 Binary files a/locale/en_GB/LC_MESSAGES/Studs.mo and b/locale/en_GB/LC_MESSAGES/Studs.mo differ diff --git a/locale/en_GB/LC_MESSAGES/Studs.po b/locale/en_GB/LC_MESSAGES/Studs.po index a191040..ce98e9a 100644 --- a/locale/en_GB/LC_MESSAGES/Studs.po +++ b/locale/en_GB/LC_MESSAGES/Studs.po @@ -388,8 +388,8 @@ msgid "Comments" msgstr "Comments" #: studs.php:310 -msgid "If you want to vote in this poll, you have to give your name, choose the values that fit best for you
    (without paying attention to the choices of the other voters) and validate with the plus button at the end of the line." -msgstr "If you want to vote in this poll, you have to give your name, choose the values that fit best for you
    (without paying attention to the choices of the other voters) and validate with the plus button at the end of the line." +msgid "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." +msgstr "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." #: studs.php:517 #: adminstuds.php:886 diff --git a/locale/es_ES/LC_MESSAGES/Studs.mo b/locale/es_ES/LC_MESSAGES/Studs.mo index ab0a92d..b6d9de1 100644 Binary files a/locale/es_ES/LC_MESSAGES/Studs.mo and b/locale/es_ES/LC_MESSAGES/Studs.mo differ diff --git a/locale/es_ES/LC_MESSAGES/Studs.po b/locale/es_ES/LC_MESSAGES/Studs.po index 3084fce..6685449 100644 --- a/locale/es_ES/LC_MESSAGES/Studs.po +++ b/locale/es_ES/LC_MESSAGES/Studs.po @@ -400,8 +400,8 @@ msgid "Comments" msgstr "Comentarios" #: studs.php:261 -msgid "If you want to vote in this poll, you have to give your name, choose the values that fit best for you
    (without paying attention to the choices of the other voters) and validate with the plus button at the end of the line." -msgstr "Para participar a esta encuesta, introduzca su nombre, elige todas las valores que son apriopriadas
    (sin tener en cuenta los otros encuestados) y validar su seleccion con el botón verde a la fin de línea." +msgid "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." +msgstr "Para participar a esta encuesta, introduzca su nombre, elige todas las valores que son apriopriadas
    y validar su seleccion con el botón verde a la fin de línea." #: studs.php:445 #: adminstuds.php:806 diff --git a/locale/fr_FR/LC_MESSAGES/Studs.mo b/locale/fr_FR/LC_MESSAGES/Studs.mo index b4a2568..bbe822c 100644 Binary files a/locale/fr_FR/LC_MESSAGES/Studs.mo and b/locale/fr_FR/LC_MESSAGES/Studs.mo differ diff --git a/locale/fr_FR/LC_MESSAGES/Studs.po b/locale/fr_FR/LC_MESSAGES/Studs.po index 99d1a23..c508df9 100644 --- a/locale/fr_FR/LC_MESSAGES/Studs.po +++ b/locale/fr_FR/LC_MESSAGES/Studs.po @@ -374,8 +374,8 @@ msgid "Comments" msgstr "Commentaire de l'auteur" #: studs.php:238 -msgid "If you want to vote in this poll, you have to give your name, choose the values that fit best for you
    (without paying attention to the choices of the other voters) and validate with the plus button at the end of the line." -msgstr "Pour participer à ce sondage, veuillez entrer votre nom, choisir toutes les valeurs qui vous conviennent
    et valider votre choix avec le bouton en bout de ligne." +msgid "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." +msgstr "Pour participer à ce sondage, veuillez entrer votre nom, choisir toutes les valeurs qui vous conviennent
    et valider votre choix avec le bouton en bout de ligne." #: studs.php:456 msgid "Participate" @@ -395,7 +395,7 @@ msgstr "Meilleur choix" #: adminstuds.php:924 #: adminstuds.php:926 msgid "for" -msgstr "à" +msgstr "à" #: studs.php:534 #: adminstuds.php:947 diff --git a/maintenance.php b/maintenance.php index 576c9a8..ea3f8d2 100644 --- a/maintenance.php +++ b/maintenance.php @@ -39,12 +39,12 @@ include_once('bandeaux.php'); -echo ''."\n"; -echo ''."\n"; +echo ''."\n"; +echo ''."\n"; echo ''."\n"; echo ''."\n"; echo 'Maintenance '.NOMAPPLICATION.' '."\n"; -echo ''."\n"; +echo ''."\n"; echo ''."\n"; echo ''."\n"; logo(); @@ -60,4 +60,4 @@ echo ''."\n"; sur_bandeau_pied(); bandeau_pied(); echo ''."\n"; -echo ''."\n"; \ No newline at end of file +echo ''."\n"; diff --git a/sources/sources.php b/sources/sources.php index 04d9fc9..a086386 100644 --- a/sources/sources.php +++ b/sources/sources.php @@ -40,7 +40,7 @@ include '../bandeaux.php'; echo ''."\n"; -echo ''."\n"; +echo ''."\n"; echo ''."\n"; echo ''."\n"; echo 'Sources '.NOMAPPLICATION.''."\n"; @@ -61,4 +61,4 @@ echo ''."\n"; // Affichage du bandeau de pied bandeau_pied(); echo ''."\n"; -echo ''."\n"; \ No newline at end of file +echo ''."\n"; diff --git a/studs.php b/studs.php index a0c774f..16cd29e 100644 --- a/studs.php +++ b/studs.php @@ -183,8 +183,11 @@ if (!is_error(NO_POLL) && (isset($_POST["boutonp"]) || isset($_POST["boutonp_x"] $err |= NAME_EMPTY; } } - -print_header(true, $dsondage->titre); +if($err != 0) { + print_header(true, _("Error!").' - '.$dsondage->titre); +} else { + print_header(true, $dsondage->titre); +} echo ''."\n"; framanav(); logo(); @@ -219,9 +222,8 @@ if($err != 0) { if(is_error(NO_POLL_ID) || is_error(NO_POLL)) { echo '
    '."\n"; - print "

    " . _("This poll doesn't exist !") . "

    "."\n"; - print _("Back to the homepage of") . ' '. NOMAPPLICATION . '.'."\n"; - echo '



    '."\n"; + print "

    " . _("This poll doesn't exist !") . "

    "."\n"; + print _("Back to the homepage of") . ' '. NOMAPPLICATION . '.'."\n"; echo '
    '."\n"; bandeau_pied(); @@ -232,16 +234,16 @@ if($err != 0) { } echo '
    '; //ajout pyg cohérence graphique -echo ''; +echo ''; echo '
    '."\n"; //affichage du titre du sondage $titre=str_replace("\\","",$dsondage->titre); -echo '

    '.stripslashes($titre).'

    '."\n"; +echo '

    '.stripslashes($titre).'

    '."\n"; //affichage du nom de l'auteur du sondage -echo '
    '. _("Initiator of the poll") .' : '.stripslashes($dsondage->nom_admin).'
    '."\n"; -echo '
    '.'Adresse : '.getUrlSondage($dsondage->id_sondage).'
    '."\n";; +echo '

    '. _("Initiator of the poll") .' : '.stripslashes($dsondage->nom_admin).'

    '."\n"; +echo '

    '.'Adresse : '.getUrlSondage($dsondage->id_sondage).'

    '."\n";; //affichage des commentaires du sondage @@ -252,15 +254,13 @@ if ($dsondage->commentaires) { echo ''. $commentaires .''; echo '
    '."\n"; } - -echo '
    '."\n"; echo '
    '."\n"; -echo ''."\n"; +echo ''."\n"; echo ''; // Todo : add CSRF protection echo '
    '."\n"; -echo _("If you want to vote in this poll, you have to give your name, choose the values that fit best for you
    (without paying attention to the choices of the other voters) and validate with the plus button at the end of the line.") ."\n"; +echo _("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.") ."\n"; echo '
    '."\n"; // Debut de l'affichage des resultats du sondage @@ -416,12 +416,12 @@ if ($dsondage->format=="D"||$dsondage->format=="D+") { //affichage des sujets du sondage echo '
    '."\n"; - echo ''."\n"; + echo ''."\n"; for ($i=0; isset($toutsujet[$i]); $i++) { - echo ''."\n"; + echo ''."\n"; } - + echo ''."\n"; echo ''."\n"; } @@ -442,7 +442,7 @@ while ($data = $user_studs->FetchNextObject(false)) { $nombase=str_replace("°","'",$data->nom); echo stripslashes($nombase).''."\n"; - // Les réponses qu'il a choisit + // Les réponses qu'il a choisies $ensemblereponses = $data->reponses; // ligne d'un usager pré-authentifié @@ -453,7 +453,7 @@ while ($data = $user_studs->FetchNextObject(false)) { for ($k=0; $k < $nbcolonnes; $k++) { // on remplace les choix de l'utilisateur par une ligne de checkbox pour recuperer de nouvelles valeurs if ($compteur == $ligneamodifier) { - echo ''."\n"; + echo ''."\n"; } //demande de confirmation pour modification de ligne for ($i=0;$i<$nblignes;$i++) { if (isset($_POST["modifierligne$i"]) || isset($_POST['modifierligne'.$i.'_x'])) { if ($compteur == $i) { - echo ''."\n"; + echo ''."\n"; } } } @@ -500,13 +500,13 @@ if (! ( USE_REMOTE_USER && isset($_SERVER['REMOTE_USER']) ) || !$user_mod) { } else { $nom = 'Votre nom'; } - echo ''."\n"; + echo ''."\n"; echo ''."\n"; // affichage des cases de formulaire checkbox pour un nouveau choix for ($i=0;$i<$nbcolonnes;$i++) { - echo ''."\n"; + echo ''."\n"; echo ''."\n"; } @@ -537,10 +537,10 @@ echo ''."\n".''."\n"; // Affichage des différentes sommes des colonnes existantes echo ''."\n"; -echo ''."\n"; for ($i=0; $i < $nbcolonnes; $i++) { if (isset($somme[$i]) === true) { @@ -555,19 +555,19 @@ for ($i=0; $i < $nbcolonnes; $i++) { echo ''."\n"; } - +echo ''."\n"; echo ''."\n"; echo ''."\n"; echo ''."\n"; for ($i=0; $i < $nbcolonnes; $i++) { if (isset($somme[$i]) && isset($meilleurecolonne) && $somme[$i] == $meilleurecolonne) { - echo ''."\n"; + echo ''."\n"; } else { echo ''."\n"; } } - +echo ''."\n"; echo ''."\n"; echo ''."\n"; echo '
    '. _("Poll title *: ") .'
    " . _("Enter a title") . "' . _("Enter a title") . '" . _("Characters < > and \" are not permitted") . "' . _("Characters < > and \" are not permitted") . '
    '. _("Comments: ") .'
    ' . _("Characters < > and \" are not permitted") . "
    '. _("Your name*: ") .''; +echo '
    '; if (USE_REMOTE_USER && isset($_SERVER['REMOTE_USER'])) { echo ''.stripslashes($_SESSION["nom"]).'" . _("Enter a name") . "" . _("Enter a name") . "" . _("Characters < > and \" are not permitted") . "" . _("Characters < > and \" are not permitted") . "
    '. _("Your e-mail address *: ") .''; +echo '
    '; if (USE_REMOTE_USER && isset($_SERVER['REMOTE_USER'])) { echo ''.$_SESSION["adresse"].'" . _("Enter an email address") . " " . _("Enter an email address") . " " . _("The address is not correct! (You should enter a valid email address in order to receive the link to your poll)") . "" . _("The address is not correct! (You should enter a valid email address in order to receive the link to your poll)") . "
    '.stripslashes($toutsujet[$i]).''.stripslashes($toutsujet[$i]).'
    FetchNextObject(false)) { //a la fin de chaque ligne se trouve les boutons modifier if ($compteur != $ligneamodifier && ($dsondage->format=="A+"||$dsondage->format=="D+") && $mod_ok) { - echo '
    '; +echo ''; // si on a plus de 8 colonnes, on affiche un second bouton "valider mes choix" echo ($nbcolonnes>8) ?'' : ""; -echo _("Addition") .''."\n"; +echo _("Addition") .''.$affichesomme.'
    ' . _('Best choice') . '' . _('Best choice') . '
    '."\n"; @@ -620,9 +620,9 @@ echo '

    '."\n"; // Affichage du meilleur choix if ($compteursujet == "1" && isset($meilleurecolonne)) { - print 'Meilleur choix ' . _('The best choice at this time is:') . "".stripslashes($meilleursujet)." " . _('with') . " $meilleurecolonne " . $vote_str . ".\n"; + print 'Meilleur choix ' . _('The best choice at this time is:') . "".stripslashes($meilleursujet)." " . _('with') . " $meilleurecolonne " . $vote_str . ".\n"; } elseif (isset($meilleurecolonne)) { - print 'Meilleur choix ' . _('The bests choices at this time are:') . " ".stripslashes($meilleursujet)." " . _('with') . " $meilleurecolonne " . $vote_str . ".\n"; + print 'Meilleur choix ' . _('The bests choices at this time are:') . " ".stripslashes($meilleursujet)." " . _('with') . " $meilleurecolonne " . $vote_str . ".\n"; } echo '

    '; @@ -640,33 +640,33 @@ if ($comment_user->RecordCount() != 0) { } //affichage de la case permettant de rajouter un commentaire par les utilisateurs -print '
    ' .'

    ' ._("Add a comment in the poll:") . '

    ' . "\n"; +print '
    ' .'
    ' ._("Add a comment in the poll:") . '' . "\n"; if (isset($_SESSION['nom']) === false) { $nom = ''; } else { $nom = stripslashes($_SESSION['nom']); } -echo _("Name") .' : '; -echo '
    '."\n"; - -echo ''."\n"; -echo '
    '."\n"; -echo ''."\n"; +echo '

    : '; +echo '

    '."\n"; +echo '

    :
    '; +echo '

    '."\n"; +echo '

    '."\n"; +echo '
    '."\n"; // Focus javascript sur la case de texte du formulaire echo ''."\n"; echo '
    '."\n"; echo ''; -echo ''."\n"; +echo ''."\n"; -echo '
    '; // ajout pyg cohérence graphique +//echo '
    '; // ajout pyg cohérence graphique bandeau_pied_mobile(); // Affichage du bandeau de pied diff --git a/style.css b/style.css index b96ba1e..946de00 100644 --- a/style.css +++ b/style.css @@ -62,7 +62,17 @@ img { box-sizing:content-box; } +/* a11y rules*/ +a:focus { +outline:#000 dotted 1px; +} + /*bandeau de titre*/ + +h1 { + margin:0; +} + .framorange { color: #FF8400; display: inline; @@ -88,7 +98,7 @@ div.bandeau{ background-color: #EAEAFF; color:white; vertical-align:middle; - font-size:42px; + font-size:1em; font-family:arial; padding:8px; height:40px; @@ -115,7 +125,8 @@ div.logo{ padding-top: 30px; } /*Sous bandeau avec bouton de navigation*/ -div.bandeautitre{ +.bandeautitre{ + margin:0; height:17px; background-color: #EAEAFF; font-size:14px; @@ -125,7 +136,7 @@ div.bandeautitre{ font-style: italic; vertical-align:middle; font-family:arial; - padding:13px; + padding:.9em; position:static; top:57px; left:6px; @@ -134,7 +145,7 @@ div.bandeautitre{ border-bottom: 1px solid #CCC; } div.sousbandeau{ - height:17px; + min-height:17px; background-color: #C4C4FF; font-size:11px; color:black; @@ -148,9 +159,21 @@ div.sousbandeau{ left:6px; right:6px; */ /* display: none; */ - margin-top: 1.5em; + margin-top: 3em; border-top: 1px solid #999; } + +.sousbandeau ul { +margin:0; +padding:0; +display:block; +float:left; +} + +.sousbandeau ul li { +list-style:none; +display:inline; +} /*bandeau de pied*/ div.surbandeaupied{ background-color: #EAEAFF; @@ -210,7 +233,8 @@ div.bandeaupiedmobile{ text-shadow: 0 1px 0 rgba(0, 0, 0, 0.4); } */ -span.sousbandeaulangue { +ul.sousbandeaulangue { + display:block; margin-left:6px; margin-right:90px; float:right; @@ -360,6 +384,7 @@ div.cadre table.resultats { margin:0 auto; } +div.cadre th, div.cadre td { height:30px; } @@ -375,11 +400,13 @@ div.cadre td.non { width:35px; } /*Case de tableau VIDE dans affichage de sondage*/ +div.cadre th.vide, div.cadre th.sujet, div.cadre td.vide, div.cadre td.sujet { background-color: #DDDDDD; text-align:center; + padding:1px 5px; } - +div.cadre th.vide, div.cadre th.ok, div.cadre th.non, div.cadre th.sujet, div.cadre th.nom, div.cadre th.jour, div.cadre th.heure, div.cadre th.mois, div.cadre td.vide, div.cadre td.ok, div.cadre td.non, div.cadre td.sujet, div.cadre td.nom, div.cadre td.jour, div.cadre td.heure, div.cadre td.mois { border-right: 1px solid #BBB !important; border-bottom: 1px solid #BBB !important; @@ -654,3 +681,15 @@ li.error { .imprimer { float:right; } + +.error { + color:red; +} + +.margin-top { + margin-top:1em; +} + +.txt-right { +text-align:right; +} diff --git a/variables.php.template b/variables.php.template index 9fabfc8..0dfe9f6 100644 --- a/variables.php.template +++ b/variables.php.template @@ -95,8 +95,8 @@ if (@file_exists('variables.local.php')) { const STUDS_VERSION = 0.7; // Do not edit the following -$ALLOWED_LANGUAGES = array('fr_FR' => 'french', - 'en_GB' => 'english', - 'es_ES' => 'spanish', - 'de_DE' => 'german' ); +$ALLOWED_LANGUAGES = array('fr_FR' => '
  • Français
  • ', + 'en_GB' => '
  • English
  • ', + 'es_ES' => '
  • Español
  • ', + 'de_DE' => '
  • Deutsch
  • ' );