disable error handler on ajax controller

Hello,

I’m rewriting an application that uses ajax controllers that generate errors such as "Division by zero ", but the controller should continue anyway and send the result (error + XML), while Yii redirect to site/error.

I just I have to disable the behavior for these controllers, not for all.

suggest?

You should use try catch for catch the exception and manage the error as you want.

this is the worst solution, because they are almost 50 file to edit, also I have not full knowledge of it.

I hoped in the flexibility of Yii :)

otherwise I’ll add to index.php this code:


define(YII_ENABLE_EXCEPTION_HANDLER, false);

define(YII_ENABLE_ERROR_HANDLER, false);

but I dont like this :(