public static function unXss($input) {
            if (self::isTraversable($input)) {
                foreach ($input as &$i) {
                    $i = self::unXss($i);
                }
            } elseif (is_scalar($input)) {
                $input = htmlspecialchars($input, ENT_QUOTES | ENT_HTML5 | ENT_SUBSTITUTE);
            }

            return $input;
        }
public static function unXss($input) {
            if (self::isTraversable($input)) {
                foreach ($input as &$i) {
                    $i = self::unXss($i);
                }
            } elseif (is_scalar($input)) {
                $input = htmlspecialchars($input, ENT_QUOTES | ENT_HTML5 | ENT_SUBSTITUTE);
            }

            return $input;
        }
public static function unXss ( $ input ) { if ( self :: isTraversable ( $ input ) ) { foreach ( $ input as & $ i ) { $ i = self :: unXss ( $ i ) ; } } elseif ( is_scalar ( $ input ) ) { $ input = htmlspecialchars ( $ input , ENT_QUOTES | ENT_HTML5 | ENT_SUBSTITUTE ) ; } return $ input ; }
Protects the input from cross-site scripting attacks

@author Art <a.molcanovas@gmail.com>

@param string|array|Traversable $input The scalar input, or an array/Traversable

@return string|array|Traversable The escaped string. If an array or traversable was passed on, the input
withall its applicable values escaped.
@since  1.3.2 ENT_SUBSTITUTE added<br/>
1.2
Protects the input from cross - site scripting attacks