I'm just starting learning french...
authorFlorent Bruneau <florent.bruneau@polytechnique.org>
Thu, 13 Sep 2007 06:31:38 +0000 (08:31 +0200)
committerFlorent Bruneau <florent.bruneau@polytechnique.org>
Thu, 13 Sep 2007 06:31:38 +0000 (08:31 +0200)
Signed-off-by: Florent Bruneau <florent.bruneau@polytechnique.org>
classes/platalpage.php
include/geoloc.inc.php
templates/geoloc/country.tpl
templates/geoloc/init.tpl
templates/platal/acces_smtp.tpl

index bf35d60..47e1da6 100644 (file)
@@ -61,9 +61,9 @@ abstract class PlatalPage extends Smarty
 
     public function changeTpl($tpl, $type = SKINNED)
     {
-       $this->_tpl       = $tpl;
-           $this->_page_type = $type;
-       $this->assign('xorg_tpl', $tpl);
+      $this->_tpl       = $tpl;
+      $this->_page_type = $type;
+      $this->assign('xorg_tpl', $tpl);
     }
 
     // }}}
@@ -116,8 +116,8 @@ abstract class PlatalPage extends Smarty
             $this->assign('simple', true);
 
           case SKINNED:
-           $this->register_modifier('escape_html', 'escape_html');
-           $this->default_modifiers = Array('@escape_html');
+          $this->register_modifier('escape_html', 'escape_html');
+          $this->default_modifiers = Array('@escape_html');
         }
         $this->register_outputfilter('hide_emails');
         $this->addJsLink('wiki.js');
@@ -285,9 +285,9 @@ function escape_xorgDB(&$item, $key)
 function escape_html($string)
 {
     if (is_string($string)) {
-       return htmlspecialchars($string, ENT_QUOTES, 'UTF-8');
+        return htmlspecialchars($string, ENT_QUOTES, 'UTF-8');
     } else {
-       return $string;
+        return $string;
     }
 }
 
index 89ecd45..df3214a 100644 (file)
@@ -501,7 +501,7 @@ function geoloc_getData_subcountries($mapid, $sin, $minentities)
     }
 
     foreach ($countries as $i => $c) {
-        if ($c['nbPop'] > 0) {
+        if (@$c['nbPop'] > 0) {
             $lambda = pow($c['nbPop'] / $maxpop,0.3);
             $countries[$i]['color'] = 0x0000FF + round((1-$lambda) * 0xFF)*0x010100;
         }
index 809add5..c0e82c9 100644 (file)
@@ -30,7 +30,7 @@
       {if $country.nbPop > 0 or $country.id eq 0}\r
       <map x="{$country.x}" y="{$country.y}" height="{$country.height}" width="{$country.width}" ratio="{$country.rat}"/>\r
       <icon x="{$country.xPop}" y="{$country.yPop}" nb="{$country.nbPop}" size="{$country.rad}" name="{$country.name}" green="{if $country.nbPop}{$country.yellow/$country.nbPop}{else}0{/if}" blue="0" alpha="0.7"/>\r
-      <moreinfos url="country{$plset_search}mapid={$country.id}"/>\r
+      <moreinfos url="country{$plset_search|escape_html}mapid={$country.id}"/>\r
       {/if}\r
     </country>\r
     {/foreach}\r
@@ -39,7 +39,7 @@
     {foreach from=$cities item="city"}\r
     <city id="{$city.id}" name="{$city.name}">\r
       <icon x="{$city.x}" y="{$city.y}" nb="{$city.pop}" size="{$city.size}" name="{$city.name}" green="{if $city.pop}{$city.yellow/$city.pop}{else}0{/if}" blue="0"/>\r
-      <moreinfos url="city{$plset_search}cityid={$city.id}"/>\r
+      <moreinfos url="city{$plset_search|escape_html}cityid={$city.id}"/>\r
     </city>\r
     {/foreach}\r
   </cities>\r
index dfc34a8..b57ce7a 100644 (file)
@@ -46,5 +46,5 @@ zoomBarBackgroundColor="{$background}"
 textCopyright="Les règles de l'annuaire s'appliquent aussi à cette application"
 autofolder="true"
 iconSwf="icon.swf"
-scriptInfosArea="country{$plset_search}"/>
+scriptInfosArea="country{$plset_search|escape_html}"/>
 {* vim:set et sw=2 sts=2 sws=2 enc=utf-8: *}
index a2cd1f9..38e1927 100644 (file)
   Pour activer un compte SMTP/NNTP sur <strong>ssl.polytechnique.org</strong>, tape un mot de passe ci-dessous.
 {/if}
 </p>
-<form action="password/smtp" method="post" id="smtppass_form">
+<form action="password/smtp" method="post" id="smtppass_form" style="margin-top: 1em">
   <table class="tinybicol" cellpadding="3" summary="Définition du mot de passe">
     <tr>
-      <th colspan="2">
-        Définition du mot de passe
-      </th>
-    </tr>
-    <tr>
       <td class="titre">
         Mot de passe (15 caractères maximum) :
       </td>
@@ -97,9 +92,9 @@
 </form>
 <p>
   {icon name=error title="Attention"} Nous te déconseillons fortement d'utiliser le même
-  mot de passe que pour la connexion au site. En effet, contrairement au mot de passe
-  d'accès au site, sera stocké en clair dans notre base de donnée en raison des contraintes
-  technique imposées par les serveurs SMTP et NNTP.
+  mot de passe que pour la connexion au site. En effet ce mot de passe sert à accéder à des
+  services <em>moins</em> sécurisés qui nécessitent l'enregistrement de celui-ci en clair
+  dans notre base de données.
 </p>
 <p>
   Ce mot de passe peut être le même que celui d'accès au site. Il doit faire au