From 638ba75894a5f09701ad16ebb23f8cf115fe5e0a Mon Sep 17 00:00:00 2001 From: Daniel Cebrian Date: Tue, 24 Oct 2023 14:18:48 +0200 Subject: [PATCH] #12288 fixed spinner in empty page --- pandora_console/include/functions_html.php | 2 +- .../operation/network/network_report.php | 49 ++++++++++++------- .../operation/network/network_usage_map.php | 1 + 3 files changed, 34 insertions(+), 18 deletions(-) diff --git a/pandora_console/include/functions_html.php b/pandora_console/include/functions_html.php index 5481152ac6..888531e915 100644 --- a/pandora_console/include/functions_html.php +++ b/pandora_console/include/functions_html.php @@ -5409,7 +5409,7 @@ function html_print_link_with_params($text, $params=[], $type='text', $style='', $formStyle = ' style="'.$formStyle.'"'; } - $html = '
'; + $html = ''; switch ($type) { case 'image': $html .= html_print_input_image($text, $text, $text, $style, true); diff --git a/pandora_console/operation/network/network_report.php b/pandora_console/operation/network/network_report.php index cbcf1328cc..c0f1e4bc18 100644 --- a/pandora_console/operation/network/network_report.php +++ b/pandora_console/operation/network/network_report.php @@ -554,25 +554,24 @@ if (empty($data)) { 'content' => $resultsTable.$pieGraph, ] ); - - $spinner = html_print_div( - [ - 'content' => '', - 'class' => 'spinner-fixed inherit', - 'style' => 'position: initial;', - ], - true - ); - html_print_div( - [ - 'id' => 'spinner', - 'content' => '

'.__('Loading netflow data, please wait...').'

'.$spinner, - 'class' => 'invisible', - 'style' => 'position: initial;', - ] - ); } +$spinner = html_print_div( + [ + 'content' => '', + 'class' => 'spinner-fixed inherit', + 'style' => 'position: initial;', + ], + true +); +html_print_div( + [ + 'id' => 'spinner', + 'content' => '

'.__('Loading netflow data, please wait...').'

'.$spinner, + 'class' => 'invisible', + 'style' => 'position: initial;', + ] +); ?>