3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $str = '{"numRecordings":"87","numSpecies":"1","page":1,"numPages":1,"recordings":[{"id":"176356","gen":"Picoides","sp":"pubescens","ssp":"","en":"Downy Woodpecker","rec":"Jorge de Leon Cardozo","cnt":"United States","loc":"STORRS MANSFIELD, Tolland, Connecticut","lat":"41.8349","lng":"-72.1974","type":"drumming","file":"http:\/\/www.xeno-canto.org\/176356\/download","lic":"http:\/\/creativecommons.org\/licenses\/by-nc-sa\/4.0\/","url":"http:\/\/www.xeno-canto.org\/176356"}} '; $audiostring = file_get_contents($audiourl); $json_a = json_decode($audiostring, true); echo $json_a['numRecordings'];
Output for 5.2.9 - 5.6.28, 7.0.0 - 7.1.0
Notice: Undefined variable: audiourl in /in/6Fv6H on line 5 Warning: file_get_contents(): Filename cannot be empty in /in/6Fv6H on line 5
Output for hhvm-3.10.0 - 3.12.0
Notice: Undefined variable: audiourl in /in/6Fv6H on line 5 Warning: Filename cannot be empty in /in/6Fv6H on line 5
Output for 5.2.0 - 5.2.8
Notice: Undefined variable: audiourl in /in/6Fv6H on line 5
Output for 5.0.4 - 5.1.6
Notice: Undefined variable: audiourl in /in/6Fv6H on line 5 Fatal error: Call to undefined function json_decode() in /in/6Fv6H on line 6
Process exited with code 255.
Output for 5.0.0 - 5.0.3
Notice: Undefined variable: audiourl in /in/6Fv6H on line 5 Fatal error: Call to undefined function json_decode() in /in/6Fv6H on line 6
Process exited with code 255.
Output for 4.4.5 - 4.4.9
Notice: Undefined variable: audiourl in /in/6Fv6H on line 5 Fatal error: Call to undefined function: json_decode() in /in/6Fv6H on line 6
Process exited with code 255.
Output for 4.3.2 - 4.4.4
Notice: Undefined variable: audiourl in /in/6Fv6H on line 5 Fatal error: Call to undefined function: json_decode() in /in/6Fv6H on line 6
Process exited with code 255.
Output for 4.3.0 - 4.3.1
Notice: Undefined variable: audiourl in /in/6Fv6H on line 5 Fatal error: Call to undefined function: json_decode() in /in/6Fv6H on line 6