3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php function encryptPassword($password) { $encryptedPassword = md5($password).md5("MOOYOUL"); // SHA1 암호화하고 Base64로 Encode한걸 또 다시 SHA1로 암호화 $encryptedPassword = sha1(sha1(sha1($encryptedPassword, true), true), false).sha1("MOOYOUL").sha1("merong"); return $encryptedPassword; } $original = "password"; $encrypted = encryptPassword($original); var_dump($original, $encrypted);
based on Ji5Vh
Output for 5.0.0 - 7.1.0
string(8) "password" string(120) "d2af52513f152ae233f80fbf688dbc1b0a7102495ff6404914e5442b50b9ab73d1933a0754f56827de3f89c69aa24cf5304b60f6bb2a8ffbc9fc3bde"
Output for 4.3.0 - 4.4.9
Warning: Wrong parameter count for sha1() in /in/833ii on line 6 Warning: Wrong parameter count for sha1() in /in/833ii on line 6 Warning: Wrong parameter count for sha1() in /in/833ii on line 6 string(8) "password" string(80) "5ff6404914e5442b50b9ab73d1933a0754f56827de3f89c69aa24cf5304b60f6bb2a8ffbc9fc3bde"