Possible Duplicate:
Anonymous functions pre PHP 5.3.0
Merhaba,
Ben nasıl yapabildin
$ar = array_filter($ar, function($el) {
$search = 'New York';
$name = $ar['name'];
$potentialNumber = substr($name, strlen($search));
return ((substr($name, 0, strlen($search)) == $search) && // starts with NY
($potentialNumber == '' || is_numeric($potentialNumber)); // [0-9]*
});
PHP 5.3 öncesi?