3v4l.org

run code in 300+ PHP versions simultaneously
<?php $url = 'http://maps.google.com/maps/api/geocode/json?address=Bahnhofstra%C3%9Fe+19+Gr%C3%A4fenhainichen&components=country:NL'; $ch = curl_init($url); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt($ch, CURLOPT_TIMEOUT, 5); $data = curl_exec($ch); // $data = json_decode($data); var_dump($data); if (!curl_errno($ch) && isset($data->status) && ($data->status == 'OK')) { // $latitude = $data->result[0]->geometry->location->lat; // $longitude = $data->result[0]->geometry->location->lng; // if ($dealers = User::findDealersByCoordinates($longitude, $latitude, $country->id)) { // $dealerId = $dealers[0]['dealerID']; // $websiteId = $dealers[0]['websiteID']; // } } else { // Yii::error('Curl request at Google API timeout'); } curl_close($ch);
Output for git.master, git.master_jit, rfc.property-hooks
Fatal error: Uncaught Error: Call to undefined function curl_init() in /in/uF9Hq:5 Stack trace: #0 {main} thrown in /in/uF9Hq on line 5
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:
52.92 ms | 401 KiB | 8 Q