/**
  * Looks for an exception saved in a session and prints
  * it off if it is found.
  *
  * If the config files for this project have been set
  * up to print the stack trace of an exception, that is printed
  * as well.
  */
 public static function render_exception_div_from_session()
 {
     if (isset($_SESSION['exception'])) {
         $cmf = HaddockProjectOrganisation_ConfigManagerFactory::get_instance();
         $phcm = $cmf->get_config_manager('haddock', 'public-html');
         $exception_div = new HTMLTags_ExceptionDiv($_SESSION['exception'], $phcm->are_exception_trace_lists_printed());
         echo $exception_div->get_as_string();
     } else {
         echo "<p class=\"error\">No exception set!</p>\n";
     }
 }
 * The content of the default error page.
 *
 * @copyright Clear Line Web Design, 2007-03-07 
 */
?>
<div
    id="content"
    class="error"
>
<?php 
if (isset($_SESSION['exception'])) {
    /*
     * RFI 2009-06-18
     */
    #$div_exception = new HTMLTags_ExceptionDiv($_SESSION['exception']);
    $div_exception = new HTMLTags_ExceptionDiv($_SESSION['exception'], $print_name = TRUE, $print_trace = TRUE);
    echo $div_exception->get_as_string();
} else {
    if (isset($_GET['error_message'])) {
        ?>
    <p>
        <?php 
        echo stripcslashes($_GET['error_message']) . "\n";
        ?>
    </p>
<?php 
    }
}
if (isset($_GET['return_to'])) {
    ?>
    <p>