3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $options = array('cost' => 10); $salt = 'OaZZhZgCp/VAldZFX2o6leedzq6wLT.'; echo password_hash($salt, PASSWORD_BCRYPT, $options)."\n"; echo crypt($'test123', '$2a$10$' . $salt);
based on FVYGC
Output for 7.0.0
Parse error: syntax error, unexpected ''test123'' (T_CONSTANT_ENCAPSED_STRING), expecting variable (T_VARIABLE) or '{' or '$' in /in/Gbq7V on line 6
Process exited with code 255.
Output for 5.4.10 - 5.6.16
Parse error: syntax error, unexpected ''test123'' (T_CONSTANT_ENCAPSED_STRING), expecting variable (T_VARIABLE) or '$' in /in/Gbq7V on line 6
Process exited with code 255.
Output for 5.3.20 - 5.3.29
Parse error: syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting T_VARIABLE or '$' in /in/Gbq7V on line 6
Process exited with code 255.