fixed error background image metaconsole
This commit is contained in:
parent
fc5fce8f5e
commit
12f51156f8
|
@ -205,11 +205,7 @@ switch ($activeTab) {
|
||||||
|
|
||||||
// If the background is changed the size is reseted
|
// If the background is changed the size is reseted
|
||||||
$background_now = $visualConsole['background'];
|
$background_now = $visualConsole['background'];
|
||||||
/*if ($background_now != $background && $background) {
|
|
||||||
$sizeBackground = getimagesize($config['homedir'] . '/images/console/background/' . $background);
|
|
||||||
$values['width'] = $sizeBackground[0];
|
|
||||||
$values['height'] = $sizeBackground[1];
|
|
||||||
}*/
|
|
||||||
$values['width'] = $width;
|
$values['width'] = $width;
|
||||||
$values['height'] = $height;
|
$values['height'] = $height;
|
||||||
switch ($action) {
|
switch ($action) {
|
||||||
|
@ -237,7 +233,6 @@ switch ($activeTab) {
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'save':
|
case 'save':
|
||||||
if (!defined('METACONSOLE')) {
|
|
||||||
if ($values['name'] != "" && $values['background'])
|
if ($values['name'] != "" && $values['background'])
|
||||||
$idVisualConsole = db_process_sql_insert('tlayout', $values);
|
$idVisualConsole = db_process_sql_insert('tlayout', $values);
|
||||||
else
|
else
|
||||||
|
@ -262,7 +257,6 @@ switch ($activeTab) {
|
||||||
$statusProcessInDB = array('flag' => false,
|
$statusProcessInDB = array('flag' => false,
|
||||||
'message' => ui_print_error_message(__('Could not be created.'), '', true));
|
'message' => ui_print_error_message(__('Could not be created.'), '', true));
|
||||||
}
|
}
|
||||||
}
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -1650,6 +1650,13 @@ function visual_map_print_item($mode = "read", $layoutData,
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case LABEL:
|
case LABEL:
|
||||||
|
if (get_parameter('action') == 'edit' || get_parameter('operation') == 'edit_visualmap') {
|
||||||
|
$aux_text1 = explode("<a href=\"", $text);
|
||||||
|
$aux_text2 = explode("\">", $aux_text1[1]);
|
||||||
|
$aux_text3 = explode("</a>", $aux_text2[1]);
|
||||||
|
|
||||||
|
$text = $aux_text1[0].$aux_text3[0].$aux_text3[1];
|
||||||
|
}
|
||||||
echo io_safe_output($text);
|
echo io_safe_output($text);
|
||||||
break;
|
break;
|
||||||
case ICON:
|
case ICON:
|
||||||
|
@ -2682,10 +2689,11 @@ function visual_map_print_visual_map ($id_layout, $show_links = true,
|
||||||
$mapWidth = $layout["width"];
|
$mapWidth = $layout["width"];
|
||||||
$mapHeight = $layout["height"];
|
$mapHeight = $layout["height"];
|
||||||
$backgroundImage = '';
|
$backgroundImage = '';
|
||||||
if ($layout["background"] != 'None.png' )
|
if ($layout["background"] != 'None.png' ){
|
||||||
$backgroundImage = $metaconsole_hack . 'images/console/background/' .
|
$backgroundImage = $metaconsole_hack . 'images/console/background/' .
|
||||||
$layout["background"];
|
$layout["background"];
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (defined('METACONSOLE')) {
|
if (defined('METACONSOLE')) {
|
||||||
echo "<div style='width: 100%; overflow:auto; margin: 0 auto; padding:5px;'>";
|
echo "<div style='width: 100%; overflow:auto; margin: 0 auto; padding:5px;'>";
|
||||||
|
|
Loading…
Reference in New Issue