I
I
ildar-meyker2019-12-02 20:27:12
Laravel
ildar-meyker, 2019-12-02 20:27:12

How to approach mews/purifier?

I can't understand the structure of the config/purifier.php config file. Some non-obvious use cases. How should you define your list of allowed tags and attributes? It turns out that each input will have to be passed through Purifier::clean? How can I check all incoming inputs in $request? Stupid search somewhere before the validation call? Do you use this package or others to filter input?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alex Wells, 2019-12-02
@Alex_Wells

This may only be needed where HTML is deliberately coming from the front (for example, in an editor that outputs html). In other cases, it is enough to simply use escaped output in a template engine, whether in a front-end framework or in blades.
So no, I almost never use it.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question