3v4l.org

run code in 300+ PHP versions simultaneously
<?php $contents = array ( 0 => Array ( 'id' => 1, 'title' => 'Text1', 'slug' => 'text1', ), 1 => Array ( 'id' => 2, 'title' => 'Text2', 'slug' => 'text2' ), 2 => Array ( 'id' => 3, 'title' => 'Text3', 'slug' => 'text3' ), 3 => Array ( 'id' => 4, 'title' => 'Text3', 'slug' => 'text3' ) ); $path = 'text3'; //$this->uri->segment(1); foreach($contents as $key=>$val){ if(in_array($path, $val)){ unset($contents[$key]); } } echo "<pre>"; print_r($contents);
Output for git.master, git.master_jit, rfc.property-hooks
<pre>Array ( [0] => Array ( [id] => 1 [title] => Text1 [slug] => text1 ) [1] => Array ( [id] => 2 [title] => Text2 [slug] => text2 ) )

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:
197.16 ms | 406 KiB | 5 Q