3v4l.org

run code in 500+ PHP versions simultaneously
<?php // le cache ??? $_SESSION ? $la_var_du_cache = array( 'id' => array(112, 93, 93, 11559), 'date' => array('20171123', '20180509', '20180508', '20180407'), 'heure' => array('2:00', '8:00', '8:00', '7:00'), 'num' => array( array('adulte' => 3, '60_ans_plus' => 0, '30_ans_moins' => 0 ), array('adulte' => 4, '60_ans_plus' => 0, '30_ans_moins' => 0 ), array('adulte' => 4, '60_ans_plus' => 0, '30_ans_moins' => 0 ), array('adulte' => 0, 'enfant' => 4), ), ); // date à rechercher $get_date_a_supprimer = '20171123'; // rechercher la date dans la colonne date $dateEkey = array_search($get_date_a_supprimer, $la_var_du_cache['date']); // si la recherche n'est pas en échec if($dateEkey !== false) { foreach($la_var_du_cache as $index => $pas_important) { // ou unset($get_date_in_cache[$index][$dateEkey]); array_splice($la_var_du_cache[$index], $dateEkey, 1); // détruire un élément à partir de $dateEkey } } else echo 'pas trouver<br>'; print_r($la_var_du_cache);
Output for git.master, git.master_jit, rfc.property-hooks
Array ( [id] => Array ( [0] => 93 [1] => 93 [2] => 11559 ) [date] => Array ( [0] => 20180509 [1] => 20180508 [2] => 20180407 ) [heure] => Array ( [0] => 8:00 [1] => 8:00 [2] => 7:00 ) [num] => Array ( [0] => Array ( [adulte] => 4 [60_ans_plus] => 0 [30_ans_moins] => 0 ) [1] => Array ( [adulte] => 4 [60_ans_plus] => 0 [30_ans_moins] => 0 ) [2] => Array ( [adulte] => 0 [enfant] => 4 ) ) )

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
55.84 ms | 1731 KiB | 4 Q