3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $password = "test"; echo "$password \n"; #$hashToStoreInDb = password_hash($password, PASSWORD_DEFAULT); $hashToStoreInDb = '$2M'; echo " $hashToStoreInDb \n"; # $isPasswordCorrect = password_verify($password, $hashToStoreInDb); # echo "$isPasswordCorrect \n"; $hash_crypt = crypt($password, $hashToStoreInDb); echo " $hash_crypt \n"; ?>
Output for 7.0.0 - 7.1.0
test $2M Deprecated: crypt(): Supplied salt is not valid for DES. Possible bug in provided salt format. in /in/4vuSa on line 17 $2rcByx51ejoM
Output for hhvm-3.10.0 - 3.12.0
test $2M *0
Output for 5.3.2 - 5.6.28
test $2M $2rcByx51ejoM
Output for 5.3.0 - 5.3.1
test $2M $2vU67iv49YBo
Output for 4.3.0 - 5.2.17
test $2M
Process exited with code 139.