<?php $items = ["one", "two", "three"]; $ignore = "two"; array_filter($items, function($item) { return $item !== $ignore; }); // ---- Now let's do it properly var_dump(array_filter($items, function($item) use ($ignore) { return $item !== $ignore; }));
You have javascript disabled. You will not be able to edit any code.