3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php function getResource($url, $postParams) { $curl = curl_init(); curl_setopt($curl, CURLOPT_URL, $url); curl_setopt($curl, CURLOPT_POSTFIELDS, $postParams); curl_setopt($curl, CURLOPT_FOLLOWLOCATION, true); curl_setopt($curl, CURLOPT_RETURNTRANSFER, true); curl_setopt($curl, CURLINFO_HEADER_OUT, true); curl_setopt($curl, CURLOPT_REFERER, true); curl_setopt($curl, CURLOPT_ENCODING, 'gzip,deflate'); curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1); $result = curl_exec($curl); $info = curl_getinfo($curl); curl_close($curl); if ($info['http_code'] != 200) { return false; } return $result; } getResource('http://www.tntvillage.scambioetico.org/?releaselist', 'cat=1&page=1&srcrel=person of');
Output for 7.0.0 - 7.2.6
Fatal error: Uncaught Error: Call to undefined function curl_init() in /in/994s6:5 Stack trace: #0 /in/994s6(23): getResource('http://www.tntv...', 'cat=1&page=1&sr...') #1 {main} thrown in /in/994s6 on line 5
Process exited with code 255.
Output for 5.0.0 - 5.6.28
Fatal error: Call to undefined function curl_init() in /in/994s6 on line 5
Process exited with code 255.
Output for 4.4.5 - 4.4.9
Fatal error: Call to undefined function: curl_init() in /in/994s6 on line 5
Process exited with code 255.
Output for 4.3.2 - 4.4.4
Fatal error: Call to undefined function: curl_init() in /in/994s6 on line 5
Process exited with code 255.
Output for 4.3.0 - 4.3.1
Fatal error: Call to undefined function: curl_init() in /in/994s6 on line 5