Cake custom error handler works nice with exceptions. To disable cake error handler type define('DISABLE_DEFAULT_ERROR_HANDLING' , true); in webroot/index.php
On Nov 14, 10:15 pm, Tyler Rooney <ty...@tylerrooney.ca> wrote: > I'm having trouble integrating SwiftMailer, specifically handling > exceptions. After toying around a bit, I realized I can't catch any > exceptions within CakePHP. > > try { > print 'Something...';} > > catch (Exception $e) { > print $e->getMessage(); > > } > > Outputs something like: > > Fatal error: Uncaught exception 'Exception' with message > 'something' .... > > After digging around, I discovered that PHP cannot handle Exceptions > when using Custom Error handling (seehttp://bugs.php.net/bug.php?id=44053). > > Using restore_error_handler() doesn't return to the built-in error > handling -- it might be restoring Cake's custom error handler, rather > than the built-in PHP error handler. > > Has anyone worked through this issue? > > Thanks! > T. -- You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-...@googlegroups.com. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/cake-php?hl=.