system/classes/template.class.php
branchHEAD
changeset 7384 062fc7ef2c35
parent 6928 4aa10bdc1ff6
child 7538 45315295756f
     1.1 --- a/system/classes/template.class.php	Sun Apr 12 16:15:38 2009 +0200
     1.2 +++ b/system/classes/template.class.php	Sat Oct 17 19:54:49 2009 +0200
     1.3 @@ -894,9 +894,11 @@
     1.4        $this->haltmsg($msg);
     1.5      }
     1.6  
     1.7 +    /* we won't be coming back from haltmsg() in that case anyway
     1.8      if ($this->halt_on_error == 'yes') {
     1.9        die("<b>Halted.</b>");
    1.10      }
    1.11 +    */
    1.12  
    1.13      return false;
    1.14    }
    1.15 @@ -915,7 +917,11 @@
    1.16    * @see       halt
    1.17    */
    1.18    function haltmsg($msg) {
    1.19 -    printf("<b>Template Error:</b> %s<br" . XHTML . ">\n", $msg);
    1.20 +    if ($this->halt_on_error == 'yes') {
    1.21 +      trigger_error(sprintf("Template Error: %s", $msg));
    1.22 +    } else {
    1.23 +      printf("<b>Template Error:</b> %s<br" . XHTML . ">\n", $msg);
    1.24 +    }
    1.25    }
    1.26  
    1.27  }