summaryrefslogtreecommitdiff
path: root/framework/Exceptions/TErrorHandler.php
diff options
context:
space:
mode:
Diffstat (limited to 'framework/Exceptions/TErrorHandler.php')
-rw-r--r--framework/Exceptions/TErrorHandler.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/framework/Exceptions/TErrorHandler.php b/framework/Exceptions/TErrorHandler.php
index 7d914fca..913b3ac3 100644
--- a/framework/Exceptions/TErrorHandler.php
+++ b/framework/Exceptions/TErrorHandler.php
@@ -152,7 +152,8 @@ class TErrorHandler extends TComponent implements IModule
$handling=true;
if(($response=Prado::getApplication()->getResponse())!==null)
$response->clear();
- header('Content-Type: text/html; charset=UTF-8');
+ if(!headers_sent())
+ header('Content-Type: text/html; charset=UTF-8');
if($param instanceof THttpException)
$this->handleExternalError($param->getStatusCode(),$param);
else if(Prado::getApplication()->getMode()==='Debug')