3v4l.org

run code in 300+ PHP versions simultaneously
<?php $salt = md5('static salt'); echo "SALT: " . $salt . PHP_EOL; for ($i = 0; $i < 5; $i++) { echo "PASSWORD HASH: " password_hash('reddit is fun', PASSWORD_DEFAULT, ['salt' => $salt, 'cost' => 4]) . PHP_EOL; } if (CRYPT_BLOWFISH == 1) { for ($i = 0; $i < 5; $i++) { echo "CRYPT BLOWFISH: " . crypt('reddit is fun', '$2a$04$' . $salt . '$') . PHP_EOL; } }
Output for 5.4.0 - 5.4.45, 5.5.24 - 5.5.30, 5.6.7 - 5.6.14
Parse error: syntax error, unexpected 'password_hash' (T_STRING), expecting ',' or ';' in /in/FkRXo on line 8
Process exited with code 255.

preferences:
179.25 ms | 1395 KiB | 67 Q