Anonymous View

3v4l.org

run code in 500+ PHP versions simultaneously
<?php //$_POST['event_id'] = '1'; function executeDone() { $eventId = (isset($_POST['event_id'])) ? (int)$_POST['event_id'] : ''; var_dump($eventId); } $res = executeDone(); class TestEvent { public static function getCurrentEvent() { // 開催中のイベントIDを取得 $eventId = 10; return $eventId; } } class TestStatus { private $eventId; private $userId; public function __construct($eventId, $userId) { $this->eventId = $eventId; $this->userId = $userId; } public static function process($userId) { $eventId = TestEvent::getCurrentEvent(); $obj = new TestStatus($eventId, $userId); // 処理 $data = ['num' => 1]; return $data; } } $userId = '123456'; $data = TestStatus::process($userId);
Output for git.master_jit, git.master
string(0) ""

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:
41.58 ms | 745 KiB | 4 Q