Update to PHP 7.
[cl7.git] / php / panel.php
index f65705f..d07bb6c 100644 (file)
@@ -25,16 +25,12 @@ class Panel
       # affichage des participants
       if (pg_num_rows($res_SQL) > 0)
          echo '<ul id="participants">';
-      for ($i=0; $i<pg_num_rows($res_SQL); $i++)
-      {
-         pg_data_seek($res_SQL, $i);
-         $le_participant_pseudo = pg_fetch_object($res_SQL);
-         echo '<li>', traitement_pre_affichage($le_participant_pseudo->pseudo, 8), '</li>';
-      }
+      while ($participant_pseudo = pg_fetch_object($res_SQL))
+         echo '<li>', traitement_pre_affichage($participant_pseudo->pseudo, 8), '</li>';
       if (pg_num_rows($res_SQL) > 0)
          echo '</ul>';
 
-      if($this->participant->valide)
+      if($this->participant->existe())
       {
          echo'
          <form method="post" action="index.php?';
@@ -59,7 +55,7 @@ class Panel
          <p>login / pass</p>
          <p><input type="hidden" name="log" value="1" /></p>
          <p><input type="text" name="pseudo" size="10" maxlength="30" /></p>
-         <p><input type="password" name="password" size="10" maxlength="10" /></p>
+         <p><input type="password" name="password" size="10" maxlength="15" /></p>
          <p><input type="submit" value="oki" class="submitInvisible" /></p>
          </form>
          ';