deleting folders is now recursive and should work more reliably
[squirrelmail.git] / functions / array.php
index 65498fc1c7cea0d18eb88bb310c2e2c05ff543b9..adccf776650b01cb17b87963d1a0b00f89c962f9 100644 (file)
          }
          return $r;
       }
+
+   function removeElement($array, $element) {
+      $j = 0;
+      for ($i = 0;$i < count($array);$i++)
+         if ($i != $element) {
+            $newArray[$j] = $array[$i];
+            $j++;
+         }
+
+      return $newArray;
+   }
 ?>