Answer the question
In order to leave comments, you need to log in
Yii: How to correctly throw an error from Filter ?
Good day
The controller uses its own filters, the essence of which is to check before the action whether the authorized user has exhausted the limits (For example, according to the tariff plan, he is supposed to place no more than 10 products).
Vopors - how to correctly display a warning if the user tries to add 11 products?
While implemented through CException but obviously it is not correct.
Answer the question
In order to leave comments, you need to log in
In the model, in the rules, specify your filter, and for the normal display of the message, use the message parameter
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question