Posted by romain.jouin on 09/21/05 20:40
Ok, it seems There is a mistake here, we need not to use the "else" word : function in_array_recursive($array, $val) {//search recursevly a value on an array //this value can be key or value of the arrays if(is_array($array)) foreach($array as $a => $b) if($a == $val ) return true; elseif( in_array_recursive($b, $val)) return true; if($array == $val) return true; return false; }
[Reply to this message]
Copyright © 2005-2006 Powered by Custom PHP Programming