From 88f72fdd5121c77bed63521cd83b7f864895f12a Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Sun, 19 Sep 2004 21:19:00 +0000 Subject: [PATCH] fix for bug [ 1006205 ] wiki editing broken with Safari - safari gets now recogniced as browser by the html-class - html::htmlarea show's a textarea if HTMLarea is not availible (suppresses error with safari) - dont show button to convert to html if: * HTMLarea is not availible for the browser * admin disabled it in the wiki configuration --- phpgwapi/inc/class.html.inc.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/phpgwapi/inc/class.html.inc.php b/phpgwapi/inc/class.html.inc.php index 850d651bdc..4c8980b98f 100644 --- a/phpgwapi/inc/class.html.inc.php +++ b/phpgwapi/inc/class.html.inc.php @@ -249,8 +249,13 @@ class html */ function htmlarea($name,$content='',$style='',$base_href='',$plugins='') { - if (!$plugins) $plugins = 'ContextMenu,TableOperations,SpellChecker'; if (!$style) $style = 'width:100%; min-width:500px; height:300px;'; + // check if htmlarea is availible for the browser and use a textarea if not + if (!$this->htmlarea_availible()) + { + return $this->textarea($name,$content,'style="'.$style.'"'); + } + if (!$plugins) $plugins = 'ContextMenu,TableOperations,SpellChecker'; if (!is_object($GLOBALS['phpgw']->js)) {