3v4l.org

run code in 300+ PHP versions simultaneously
<?php function underscoreToCamelCase( $string, $first_char_caps = false) { if( $first_char_caps == true ) { $string[0] = strtoupper($string[0]); } $func = create_function('$c', 'return strtoupper($c[1]);'); return preg_replace_callback('/_([a-z])/', $func, $string); } echo underscoreToCamelCase('valami_underscored_cucc');
Output for git.master, git.master_jit, rfc.property-hooks
Fatal error: Uncaught Error: Call to undefined function create_function() in /in/DmMOK:8 Stack trace: #0 /in/DmMOK(12): underscoreToCamelCase('valami_undersco...') #1 {main} thrown in /in/DmMOK on line 8
Process exited with code 255.

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:
76.06 ms | 401 KiB | 8 Q