Author: Lars Michelsen <[email protected]>
Date: Sat Jul 14 18:49:36 2012 +0200
Committer: Lars Michelsen <[email protected]>
Commit-Date: Sat Jul 14 18:49:36 2012 +0200
Bugfix: Fixed PHP error when rendering "General Configuration" dialog in some
PHP versions
---
ChangeLog | 1 +
share/server/core/classes/WuiViewEditMainCfg.php | 13 +++----------
2 files changed, 4 insertions(+), 10 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index 8cc0bed..453b606 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -29,6 +29,7 @@ Frontend
* Bugfix: Fixed icons not being displayed in IE (version 9 in this case)
* Bugfix: Fixed rendering errors in IE (below version 9)
* Bugfix: Fixed zoom function problem in Chrome
+ * Bugfix: Fixed PHP error when rendering "General Configuration" dialog in
some PHP versions
Installer
* Moved javascript compress code to make it available in omd_install script
diff --git a/share/server/core/classes/WuiViewEditMainCfg.php
b/share/server/core/classes/WuiViewEditMainCfg.php
index c922921..ef07ce5 100644
--- a/share/server/core/classes/WuiViewEditMainCfg.php
+++ b/share/server/core/classes/WuiViewEditMainCfg.php
@@ -56,7 +56,6 @@ class WuiViewEditMainCfg {
*
* @return Array Html
* @author Lars Michelsen <[email protected]>
- * FIXME: Recode to have all the HTML code in the template
*/
function getFields() {
global $CORE;
@@ -123,7 +122,9 @@ class WuiViewEditMainCfg {
$ret .= '<td class="tdfield"></td>';
} else {
$ret .= '<td class="tdfield">';
- $ret .= "<img style=\"cursor:help\"
src=\"./images/help_icon.png\" onclick=\"javascript:alert('".l($propname)."
(".l('defaultValue').": ".$arr[$propname]['default'].")')\" />";
+ $default_str =
is_array($arr[$propname]['default']) ? implode(',', $arr[$propname]['default'])
: $arr[$propname]['default'];
+ $ret .= "<img style=\"cursor:help\"
src=\"./images/help_icon.png\" "
+
."onclick=\"javascript:alert('".l($propname)." (".l('defaultValue').":
".$default_str.")')\" />";
$ret .= '</td>';
}
@@ -143,14 +144,6 @@ class WuiViewEditMainCfg {
case 'headertemplate':
$arrOpts =
$CORE->getAvailableHeaderTemplates();
break;
- case 'autoupdatefreq':
- $arrOpts =
Array(Array('value'=>'0','label'=>l('disabled')),
-
Array('value'=>'2','label'=>'2'),
-
Array('value'=>'5','label'=>'5'),
-
Array('value'=>'10','label'=>'10'),
-
Array('value'=>'25','label'=>'25'),
-
Array('value'=>'50','label'=>'50'));
- break;
}
$ret .= '<select id="'.$cat.'_'.$propname.'"
name="'.$cat.'_'.$propname.'" onBlur="validateMainConfigFieldValue(this, 0)">';
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Nagvis-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/nagvis-checkins