What do you want to save?
Add Code snippet
New code examples
-
PHP 2021-11-18 16:38:24
searching and removing element from an array php
<?php $hackers = array ('Alan Kay', 'Peter Norvig', 'Linus Trovalds', 'Larry Page'); print_r($hackers); // Search $pos = array_search('Linus Trovalds', $hackers); echo 'Linus Trovalds found at: ' . $pos; // Remove from array unset($hackers[$pos]); ... Add solution
Best helpers
Ranking is empty