3v4l.org

run code in 300+ PHP versions simultaneously
<?php function func_get_args_in_current_user_can( $capability ) { $args = array_slice( func_get_args(), 1 ); $args = array_merge( array( $capability ), $args ); var_dump($args); } function func_get_args_simplified( $capability ) { $args = func_get_args(); var_dump($args); } // Passing 1 arg. func_get_args_in_current_user_can( 'edit_posts' ); func_get_args_simplified( 'edit_posts' ); // Passing 2 args. func_get_args_in_current_user_can( 'edit_post', 10 ); func_get_args_simplified( 'edit_post', 10 ); // Passing 3 args. func_get_args_in_current_user_can( 'edit_post_meta', 10, 'meta_key' ); func_get_args_simplified( 'edit_post_meta', 10, 'meta_key' );
Output for git.master, git.master_jit, rfc.property-hooks
array(1) { [0]=> string(10) "edit_posts" } array(1) { [0]=> string(10) "edit_posts" } array(2) { [0]=> string(9) "edit_post" [1]=> int(10) } array(2) { [0]=> string(9) "edit_post" [1]=> int(10) } array(3) { [0]=> string(14) "edit_post_meta" [1]=> int(10) [2]=> string(8) "meta_key" } array(3) { [0]=> string(14) "edit_post_meta" [1]=> int(10) [2]=> string(8) "meta_key" }

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:
54.4 ms | 402 KiB | 8 Q