diff --git a/cms/content.php b/cms/content.php index 8d34f0ad5..933f12eab 100644 --- a/cms/content.php +++ b/cms/content.php @@ -27,6 +27,7 @@ require_once('../config/cis.config.inc.php'); require_once('../include/content.class.php'); require_once('../include/template.class.php'); require_once('../include/functions.inc.php'); +require_once('../include/phrasen.class.php'); if(isset($_GET['content_id'])) $content_id = $_GET['content_id']; @@ -37,6 +38,7 @@ $version = (isset($_GET['version'])?$_GET['version']:null); $sprache = (isset($_GET['sprache'])?$_GET['sprache']:getSprache()); $sichtbar = !isset($_GET['sichtbar']); +$p = new phrasen($sprache); //XML Content laden $content = new content(); @@ -44,7 +46,19 @@ if($content->islocked($content_id)) { $uid = get_uid(); if(!$content->berechtigt($content_id, $uid)) - die($uid.': Sie haben keine Berechtigung fuer diese Seite'); + { + echo ' + + + + + +

'.CAMPUS_NAME.'

+ '.$p->t('global/keineBerechtigungFuerDieseSeite').' + + '; + exit; + } } if(!$content->getContent($content_id, $sprache, $version, $sichtbar, true)) diff --git a/include/functions.inc.php b/include/functions.inc.php index d74441cb1..99ce66b49 100644 --- a/include/functions.inc.php +++ b/include/functions.inc.php @@ -25,7 +25,7 @@ require_once(dirname(__FILE__).'/basis_db.class.php'); function get_uid() { if(isset($_SERVER['REMOTE_USER'])) - return (isset($_SERVER['REMOTE_USER'])?mb_strtolower(trim($_SERVER['REMOTE_USER'])):''); + return mb_strtolower(trim($_SERVER['REMOTE_USER'])); else { if(isset($_SESSION['user'])) @@ -41,7 +41,7 @@ function get_uid() function get_original_uid() { if(isset($_SERVER['REMOTE_USER'])) - return (isset($_SERVER['REMOTE_USER'])?mb_strtolower(trim($_SERVER['REMOTE_USER'])):''); + return mb_strtolower(trim($_SERVER['REMOTE_USER'])); else { if(isset($_SESSION['user_original'])) @@ -49,6 +49,7 @@ function get_original_uid() } } + function login_as_user($uid) { $_SESSION['user']=$uid; diff --git a/include/tw/cis_menu_global.inc.php b/include/tw/cis_menu_global.inc.php index 58a8e2e23..f2cf3c2a9 100644 --- a/include/tw/cis_menu_global.inc.php +++ b/include/tw/cis_menu_global.inc.php @@ -31,8 +31,8 @@ $p = new phrasen($sprache); ?>