3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $ss = "\u{DF}"; var_dump(utf8_decode(addslashes("\xf0\xc0\xc0\xa7 or 1=1-- -"))); $tests = array( "\x41\xC2\x3E\x42", "\xE3\x80\x22", "\x41\x98\xBA\x42\xE2\x98\x43\xE2\x98\xBA\xE2\x98", ); foreach ($tests as $t) { var_dump(bin2hex(utf8_decode($t))); } echo "Done.\n";
based on uPVK8
Output for 5.2.15 - 5.2.17, 5.3.4 - 7.2.0
string(12) "? or 1=1-- -" string(8) "413f3e42" string(4) "3f22" string(16) "413f3f423f433f3f" Done.
Output for 4.3.0 - 5.2.14, 5.3.0 - 5.3.3
string(12) "' or 1=1-- -" string(6) "41be42" string(2) "3f" string(14) "4198ba423f3f3f" Done.