3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $input = array( array( 'url' => 'ellen.com', 'des' => 'w', 'size' => '850' ), array( 'url' => 'ellen.com', 'des' => 'w', 'size' => '640' ), array( 'url' => 'ellen.com', 'des' => 'w', 'size' => '330' ), array( 'url' => 'ellen.com', 'des' => 'w', 'size' => '240' ) ); foreach ( $value as $input ) { $srcset .= $input['url'] . ' ' . $input['size'] . $input['des'] . ', '; } // echo implode(', ', array_map(function ($entry) { // return $entry['url'] . ' ' . $entry['size'] . $entry['des']; // }, $input));
based on VlU9h
Output for 5.3.19 - 7.2.0
Notice: Undefined variable: value in /in/GbAUk on line 24 Warning: Invalid argument supplied for foreach() in /in/GbAUk on line 24