3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php var_dump(array_unique( array_map( function(&$val) { return strtoupper($val); }, openssl_get_md_methods() ) ));
Output for 7.0.20, 7.1.5 - 7.2.0
array(13) { [0]=> string(10) "BLAKE2B512" [1]=> string(10) "BLAKE2S256" [2]=> string(3) "MD4" [3]=> string(3) "MD5" [4]=> string(8) "MD5-SHA1" [5]=> string(4) "MDC2" [6]=> string(9) "RIPEMD160" [7]=> string(4) "SHA1" [8]=> string(6) "SHA224" [9]=> string(6) "SHA256" [10]=> string(6) "SHA384" [11]=> string(6) "SHA512" [24]=> string(9) "WHIRLPOOL" }
Output for 5.4.15 - 5.4.19, 5.4.21 - 7.0.6, 7.1.0
array(16) { [0]=> string(3) "DSA" [1]=> string(7) "DSA-SHA" [2]=> string(3) "MD4" [3]=> string(3) "MD5" [4]=> string(4) "MDC2" [5]=> string(9) "RIPEMD160" [6]=> string(3) "SHA" [7]=> string(4) "SHA1" [8]=> string(6) "SHA224" [9]=> string(6) "SHA256" [10]=> string(6) "SHA384" [11]=> string(6) "SHA512" [12]=> string(13) "DSAENCRYPTION" [13]=> string(10) "DSAWITHSHA" [14]=> string(15) "ECDSA-WITH-SHA1" [25]=> string(9) "WHIRLPOOL" }
Output for 5.3.0 - 5.4.14, 5.4.20
Fatal error: Call to undefined function openssl_get_md_methods() in /in/JJSvL on line 9
Process exited with code 255.
Output for 4.4.2 - 4.4.9, 5.1.0 - 5.2.17
Parse error: syntax error, unexpected T_FUNCTION, expecting ')' in /in/JJSvL on line 5
Process exited with code 255.
Output for 4.3.0 - 4.3.1, 4.3.5 - 4.4.1, 5.0.0 - 5.0.5
Parse error: parse error, unexpected T_FUNCTION, expecting ')' in /in/JJSvL on line 5
Process exited with code 255.
Output for 4.3.2 - 4.3.4
Parse error: parse error, expecting `')'' in /in/JJSvL on line 5
Process exited with code 255.