DASPRiD / Formidable

PHP 7 form library for handling user input
BSD 2-Clause "Simplified" License
27 stars 7 forks source link

Question about helpers #17

Closed open-it closed 6 years ago

open-it commented 6 years ago

I am trying your lib for a small project and I don't really get why you need to format the html errors with htmlspecialchars ? This enforce me to do a | raw in my view (I try it with zend expressive and twig).

https://github.com/DASPRiD/Formidable/blob/00610576fc5f1e2908a4533518247bdcc0d952c0/src/Helper/ErrorList.php#L40

DASPRiD commented 6 years ago

Because the ErrorList helper, like all helpers, returns valid HTML, not plain text.