[Trivialibre] r469 - trivialibre/trunk

trivialibre at enix.org trivialibre at enix.org
Dim 4 Mar 19:25:24 CET 2007


Author: thomas
Date: Sun Mar  4 19:25:24 2007
New Revision: 469

Log:
Remove useless code.



Modified:
   trivialibre/trunk/moderation.php

Modified: trivialibre/trunk/moderation.php
==============================================================================
--- trivialibre/trunk/moderation.php	(original)
+++ trivialibre/trunk/moderation.php	Sun Mar  4 19:25:24 2007
@@ -45,13 +45,6 @@
 
 $i = 0;
 
-$hasedit = false;
-foreach($_POST as $key => $value)
-{
-  if (ereg ("^edit\-[0-9]*$", $key))
-    $hasedit = true;
-}
-
 echo "<table width=\"100%\">\n";
 while ($item = mysql_fetch_object($req))
 {
@@ -76,18 +69,9 @@
    * If a question is being edited, do not display the
    * validate/edit/delete buttons for the other questions.
    */
-  if ($hasedit)
-    {
-      echo " <td></td>";
-      echo " <td></td>";
-      echo " <td></td>";
-    }
-  else
-    {
-      echo " <td><a href=\"validate.php?id=" . $item->id . "\">Valider</a><br/>";
-      echo " <a href=\"edit.php?id=" . $item->id . "\">Éditer</a><br/>";
-      echo " <a href=\"delete.php?id=" . $item->id . "\">Supprimer</a></td>";
-    }
+  echo " <td><a href=\"validate.php?id=" . $item->id . "\">Valider</a><br/>";
+  echo " <a href=\"edit.php?id=" . $item->id . "\">Éditer</a><br/>";
+  echo " <a href=\"delete.php?id=" . $item->id . "\">Supprimer</a></td>";
 
   echo "</tr>\n";
 }


Plus d'informations sur la liste de diffusion Trivialibre