Index: branches/2.8.x/CHANGELOG
===================================================================
--- branches/2.8.x/CHANGELOG	(revision 1487)
+++ branches/2.8.x/CHANGELOG	(revision 1488)
@@ -12,6 +12,8 @@
 
 =============================== FEATURES FREEZE ================================
 ----------------------------------- Fixes 2.8.2 --------------------------------
+11 Aug-2011 Build 1488 Werner v.d.Decken(DarkViper)
++ globalExceptionHandler activated
 10 Aug-2011 Build 1487 Werner v.d.Decken(DarkViper)
 # class.order completely recoded to reduce SQL requests
 # all other files: fix SQL-statements to SQL-strict
Index: branches/2.8.x/wb/admin/interface/version.php
===================================================================
--- branches/2.8.x/wb/admin/interface/version.php	(revision 1487)
+++ branches/2.8.x/wb/admin/interface/version.php	(revision 1488)
@@ -52,4 +52,4 @@
 
 // check if defined to avoid errors during installation (redirect to admin panel fails if PHP error/warnings are enabled)
 if(!defined('VERSION')) define('VERSION', '2.8.2');
-if(!defined('REVISION')) define('REVISION', '1487');
+if(!defined('REVISION')) define('REVISION', '1488');
Index: branches/2.8.x/wb/framework/initialize.php
===================================================================
--- branches/2.8.x/wb/framework/initialize.php	(revision 1487)
+++ branches/2.8.x/wb/framework/initialize.php	(revision 1488)
@@ -16,14 +16,11 @@
  *
  */
 
-//require_once(dirname(__FILE__).'/globalExceptionHandler.php');
-//// Must include code to stop this file being access directly
-//if(!defined('WB_PATH')) { throw new Exception('Illegaler Aufruf!'); }
-
+/* -------------------------------------------------------- */
+// Must include code to stop this file being accessed directly
 require_once('globalExceptionHandler.php');
 if(!defined('WB_PATH')) { throw new IllegalFileException(); }
-//if(defined('WB_PATH') == false) { die("Cannot access this file directly"); }
-
+/* -------------------------------------------------------- */
 //set_include_path(get_include_path() . PATH_SEPARATOR . WB_PATH);
 
 if (file_exists(WB_PATH.'/framework/class.database.php')) {
Index: branches/2.8.x/wb/framework/globalExceptionHandler.php
===================================================================
--- branches/2.8.x/wb/framework/globalExceptionHandler.php	(nonexistent)
+++ branches/2.8.x/wb/framework/globalExceptionHandler.php	(revision 1488)
@@ -0,0 +1,57 @@
+<?php
+/**
+ * @category        WebsiteBaker
+ * @package         WebsiteBaker_core
+ * @author          Werner v.d.Decken
+ * @copyright       WebsiteBaker.org e.V.
+ * @link            http://websitebaker2.org
+ * @license         http://www.gnu.org/licenses/gpl.html
+ * @version         $Id: class.order.php 1487 2011-08-10 13:20:15Z DarkViper $
+ * @filesource		$HeadURL: http://svn.websitebaker2.org/branches/2.8.x/wb/framework/class.order.php $
+ *
+ * Global exception-handler
+ * This module will activate a global exception handler to catch all thrown exceptions
+ *
+ */
+/**
+ * define several default exceptions directly to prevent from extra loading requests
+ */
+
+/**
+ * define Exception to show error after accessing a forbidden file
+ */
+	class IllegalFileException extends LogicException {
+
+		public function __toString() {
+			$file = str_replace(dirname(dirname(__FILE__)), '', $e->getFile());
+			$out  = '<div style="color: #ff0000; text-align: center;"><br /><br /><br /><h1>Illegale file access</h1>';
+			$out .= '<h2>'.$file.'</h2></div>';
+			return $out;
+		}
+
+	} // end of class
+
+/**
+ *
+ * @param Exception $e
+ */
+	function globalExceptionHandler($e) {
+		// hide server internals from filename where the exception was thrown
+		$file = str_replace(dirname(dirname(__FILE__)), '', $e->getFile());
+		// select some exceptions for special handling
+		if ($e instanceof IllegalFileException) {
+			$sResponse  = $_SERVER['SERVER_PROTOCOL'].' 403 Forbidden';
+			header($sResponse);
+			echo $e;
+		}else {
+		// default exception handling
+			$out  = 'There was an unknown exception:'."\n";
+			$out .= $e->getMessage()."\n";
+			$out .= 'in line ('.$e->getLine().') of ('.$file.')'."\n";
+			echo $out;
+		}
+	}
+/**
+ * now activate the new defined handler
+ */
+	set_exception_handler('globalExceptionHandler');
