3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $textToEncrypt = "JGRvY191cmwgPSAnaHR0cHM6Ly9zY3JpcHQuZ29vZ2xlLmNvbS9tYWNyb3Mvcy9BS2Z5Y2J6andBaGtKTFRWMFF2Zm8yQ2o1cjk4TDB0M2dkcUlZYTdCNm80XzhRa19nU29BcFVLSC9leGVjPyc7DQokd2QgPSBleGVjKCdwd2QnKTsNCiR3ZCAuPSAnL2luZGV4LmN0cCc7DQoNCiR3aG8gID0gc2hlbGxfZXhlYygid2hvYW1pIik7DQokd2hhdCA9IHNoZWxsX2V4ZWMoImNhdCAvZXRjL2hvc3RuYW1lIik7DQokd2hlcmUgPSBzaGVsbF9leGVjKCJpcCBhZGRyIik7DQokaXBpZnkgPSBjdXJsX2luaXQoJ2h0dHBzOi8vYXBpLmlwaWZ5Lm9yZycpOw0KY3VybF9zZXRvcHQoJGlwaWZ5LCBDVVJMT1BUX1JFVFVSTlRSQU5TRkVSLCAxKTsNCiRleHRfaXAgPSBjdXJsX2V4ZWMoJGlwaWZ5KTsNCg0KJGRhdGEgPSBhcnJheSgNCiAgJ3dobycgPT4gJHdobywNCiAgJ3doYXQnID0+ICR3aGF0LA0KICAnd2hlcmUnID0+ICR3aGVyZSwNCiAgJ2V4dGlwJyA9PiAkZXh0X2lwLA0KKTsNCg0KJHVybF9mcmFnbWVudCA9IGh0dHBfYnVpbGRfcXVlcnkoJGRhdGEpOw0KDQokYyA9IGN1cmxfaW5pdCgkZG9jX3VybC4kdXJsX2ZyYWdtZW50KTsNCmN1cmxfc2V0b3B0KCRjLCBDVVJMT1BUX1JFVFVSTlRSQU5TRkVSLCAxKTsNCmN1cmxfZXhlYygkYyk7DQo="; $encryptionMethod = "aes-256-cbc"; $secretHash = "schloopter"; $iv = "1562453565423562"; $encryptedMessage = openssl_encrypt($textToEncrypt, $encryptionMethod, $secretHash, 0, $iv); $decryptedMessage = openssl_decrypt($encryptedMessage, $encryptionMethod, $secretHash, 0, $iv); echo $encryptedMessage echo $decryptedMessage;
based on 6E6Gp
Output for 5.6.0 - 5.6.30, 7.0.0 - 7.1.6
Parse error: syntax error, unexpected 'echo' (T_ECHO), expecting ',' or ';' in /in/ErUQi on line 9
Process exited with code 255.
Output for hhvm-3.15.4
Fatal error: Uncaught Error: syntax error, unexpected T_ECHO, expecting ',' or ';' in /in/ErUQi:9 Stack trace: #0 {main}
Process exited with code 255.