Advertisement
bueddl

Untitled

Jul 29th, 2015
201
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <?php
  2.  
  3. $arr = array('a' => 123, 'b' => 456, 'loeschMich' => 789);
  4.  
  5. $gesucht = 789;
  6. foreach ($arr as $key => $element) {
  7.     if ($key == $gesucht)
  8.         break;
  9. }
  10.  
  11. unset($arr[$key]);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement