3v4l.org

run code in 300+ PHP versions simultaneously
<?php $str = "\x1B"; print "Compat: " . htmlspecialchars($str, ENT_COMPAT, 'UTF-8') . "\n"; print "Quotes: " . htmlspecialchars($str, ENT_QUOTES, 'UTF-8') . "\n"; print "XML: " . htmlspecialchars($str, ENT_XML1, 'UTF-8') . "\n"; print "XHTML: " . htmlspecialchars($str, ENT_XHTML, 'UTF-8') . "\n"; print "HTML5: " . htmlspecialchars($str, ENT_HTML5, 'UTF-8') . "\n"; /*print "XML+Disallowed: " . htmlspecialchars($str, ENT_XML1 | ENT_DISALLOWED, 'UTF-8') . "\n"; print "XHTML+Disallowed: " . htmlspecialchars($str, ENT_XHTML | ENT_DISALLOWED, 'UTF-8') . "\n"; print "HTML5+Disallowed: " . htmlspecialchars($str, ENT_HTML5 | ENT_DISALLOWED, 'UTF-8') . "\n";*/
Output for git.master, git.master_jit, rfc.property-hooks
Compat:  Quotes:  XML:  XHTML:  HTML5: 

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
36.6 ms | 401 KiB | 8 Q