3v4l.org

run code in 300+ PHP versions simultaneously
<?php class WP_REST_Global_Styles_Controller { public function update_item() { echo "\n" . __METHOD__ . "\n"; $this->prepare_item_for_database(); } protected function prepare_item_for_database() { echo "\n" . __METHOD__ . "\n"; $this->validate_custom_css(); } private function validate_custom_css() { echo __METHOD__ . "()\n"; } } class WP_REST_Global_Styles_Controller_X_X extends WP_REST_Global_Styles_Controller { public function update_item() { echo "\n" . __METHOD__ . "\n"; // some custom code. $this->prepare_item_for_database(); } /** * Want to invoke this method, not the parent's method. */ protected function validate_custom_css() { echo __METHOD__ . "()\n"; } } ( new WP_REST_Global_Styles_Controller_X_X() )->update_item();
Output for git.master, git.master_jit, rfc.property-hooks
WP_REST_Global_Styles_Controller_X_X::update_item WP_REST_Global_Styles_Controller::prepare_item_for_database WP_REST_Global_Styles_Controller::validate_custom_css()

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:
31.26 ms | 405 KiB | 5 Q