From 6cb0ab55527693314220f2c12b31a61320af6386 Mon Sep 17 00:00:00 2001 From: hickert Date: Thu, 2 Nov 2006 09:13:06 +0000 Subject: [PATCH] Updated render fucntion again git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@4994 594d385d-05f5-0310-b6e9-bd551577e9d8 --- include/smarty/plugins/block.render.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/include/smarty/plugins/block.render.php b/include/smarty/plugins/block.render.php index df8c6e700..dd26c6fd2 100755 --- a/include/smarty/plugins/block.render.php +++ b/include/smarty/plugins/block.render.php @@ -20,6 +20,8 @@ function smarty_block_render($params, $text, &$smarty) return ($text); } + $text = preg_replace ("/\n/","GOSA_LINE_BREAK",$text); + /* Disable objects, but keep those active that have mode=read_active */ if(!(isset($params['mode']) && $params['mode']=='read_active')){ @@ -48,7 +50,7 @@ function smarty_block_render($params, $text, &$smarty) /* Read only */ if(preg_match("/r/i",$acl)){ - return($text); + return(preg_replace("/GOSA_LINE_BREAK/","\n",$text)); } /* No acls */ @@ -67,7 +69,7 @@ function smarty_block_render($params, $text, &$smarty) "\\1\\2", "\\1 \\2"); $text = preg_replace($from,$to,$text); - + $text = preg_replace("/GOSA_LINE_BREAK/","\n",$text); return $text; } -- 2.30.2