maximebf / atomik

Micro framework for PHP 5.3+ [UNMAINTAINED]
MIT License
46 stars 18 forks source link

Allow to access to the exception in template #38

Closed zessx closed 10 years ago

zessx commented 10 years ago

Currently, we can't access to the exception from our custom error template (errors/error.phtml and errors/404.phtml).
This quickfix simply pass the exception object to the template, in a exception var. We then can use it simply :

<h1><?= $exception->getMessage() ?></h1>
adaniello commented 10 years ago

Very useful, thank you