Convenience method for htmlspecialchars.
h( mixed $text , boolean $double = true , string|null $charset = null )
mixed | $text | Text to wrap through htmlspecialchars. Also works with arrays, and objects. Arrays will be mapped and have all their elements escaped. Objects will be string cast if they implement a |
boolean | $double = true | Encode existing html entities. |
string|null | $charset = null | Character set to use when escaping. Defaults to config value in |
mixed Wrapped text.
© 2005–present The Cake Software Foundation, Inc.
Licensed under the MIT License.
CakePHP is a registered trademark of Cake Software Foundation, Inc.
We are not endorsed by or affiliated with CakePHP.
https://api.cakephp.org/3.8/function-h.html