<?php $a = 2; $options = array(1,2,3,4); $options = array_filter($options, function($val) use ($a) { return ($val == $a); }); var_dump($options);
You have javascript disabled. You will not be able to edit any code.