Yii Error Handling

TwitterFacebook
Get flash to fully experience Pearltrees

Error Handling

http://www.yiiframework.com/doc/guide/1.1/en/topics.error Yii provides a complete error handling framework based on the PHP 5 exception mechanism. When the application is created to handle an incoming user request, it registers its handleError method to handle PHP warnings and notices; and it registers its handleException method to handle uncaught PHP exceptions.
Y!!, on 01 February 2011 - 01:11 PM, said: http://www.yiiframework.com/forum/index.php/topic/15868-catching-all-db-related-exception/

Catching ALL db-related exception

PHP 5 has an exception model similar to that of other programming languages. http://php.net/manual/en/language.exceptions.php

Exceptions

Exception

http://php.net/manual/en/class.exception.php when you are using xdebug, exceptions message will never be shown if you use any encoding different than UTF-8, so if you are using any database with translated messages like oracle, you should ALWAYS, always, throw a exception like this