Stevie is running PHP version 5.3.8 at the moment. The constants ENT_SUBSTITUTE and ENT_HTML5 were added in PHP version 5.4.0. That means that stevie doesn't support them at the moment. One way is to remove those constants or define them:
<?php
if (!defined('ENT_SUBSTITUTE')) {
define('ENT_SUBSTITUTE', 8);
}
if (!defined('ENT_HTML5')) {
define('ENT_HTML5', 48);
}
$txt = 'hello world <html>';
$txt = htmlentities($txt, ENT_SUBSTITUTE | ENT_HTML5 ,"ISO-8859-1");
echo $txt;
?>