@@ -60,9 +60,9 @@ function display_information() {
60
60
$ selectedTheme = get_selected_theme ();
61
61
62
62
if (get_filter_request_var ('dashboard_id ' ) > 0 ) {
63
- $ _SESSION ['dashboard_id ' ] = get_filter_request_var ('dashboard_id ' );
63
+ $ _SESSION ['dashboard_id ' ] = get_filter_request_var ('dashboard_id ' );
64
64
} elseif (empty ($ _SESSION ['dashboard_id ' ])) {
65
- $ _SESSION ['dashboard_id ' ] = 1 ;
65
+ $ _SESSION ['dashboard_id ' ] = 1 ;
66
66
set_request_var ('dashboard_id ' , 1 );
67
67
} else {
68
68
set_request_var ('dashboard_id ' , $ _SESSION ['dashboard_id ' ]);
@@ -181,8 +181,8 @@ function display_information() {
181
181
182
182
// Notice about disable cacti dashboard
183
183
if (read_config_option ('hide_console ' ) != 'on ' ) {
184
- print '<table class="cactiTable"><tr><td class="textAreaNotes"> ' . __ ('You can disable rows above in <b>Configure > Settings > General > Hide Cacti Dashboard</b> and use the whole page for Intropage ' , 'intropage ' );
185
- print '<a class="pic" href=" ' . $ config ['url_path ' ] . 'settings.php?tab=general&filter=hide"><i class="intro_glyph fas fa-link"></i></a></td></tr></table></br> ' ;
184
+ print '<table class="cactiTable"><tr><td class="textAreaNotes"> ' . __ ('You can disable rows above in <b>Configure > Settings > General > Hide Cacti Dashboard</b> and use the whole page for Intropage ' , 'intropage ' );
185
+ print '<a class="pic" href=" ' . $ config ['url_path ' ] . 'settings.php?tab=general&filter=hide"><i class="intro_glyph fas fa-link"></i></a></td></tr></table></br> ' ;
186
186
}
187
187
188
188
$ dashboards = array_rekey (
@@ -223,7 +223,7 @@ function display_information() {
223
223
print '<div id="overlay"><div id="overlay_detail"></div></div> ' ;
224
224
225
225
// switch dahsboards and form
226
- print '<div> ' ;
226
+ print '<div id="intropage_main" > ' ;
227
227
print '<div class="float_left"> ' ;
228
228
print "<div class='tabs'><nav><ul> " ;
229
229
@@ -241,7 +241,7 @@ function display_information() {
241
241
// settings
242
242
print "<form method='post'> " ;
243
243
244
- print "<a href='#' class='pic' id='switch_square' title=' " . __esc ('Hide red/yellow/green square notifications ' , 'intropage ' ) . "'><i class='intro_glyph fa fa-minus-square'></i></a> " ;
244
+ print "<a href='#' class='pic' id='switch_square' title=' " . __esc ('Hide or display red/yellow/green square notifications ' , 'intropage ' ) . "'><i class='intro_glyph fa fa-minus-square'></i></a> " ;
245
245
print ' ' ;
246
246
247
247
print "<a href='#' class='pic' id='switch_copytext' title=' " . __esc ('Disable panel move/enable copy text from panel ' , 'intropage ' ) . "'><i class='intro_glyph fa fa-clone'></i></a> " ;
@@ -451,14 +451,18 @@ function display_information() {
451
451
452
452
print '</select> ' ;
453
453
print '</form> ' ;
454
- // end of settings
455
454
456
455
print '</div> ' ;
457
456
print '<br style="clear: both" /> ' ;
458
457
print '</div> ' ;
459
458
460
- print '<div id="megaobal"> ' ;
461
- print '<ul id="obal"> ' ;
459
+ print '<div id="main_container"> ' ;
460
+
461
+ if ($ display_wide == 'on ' ) {
462
+ print '<ul id="panel_container" class="container_col_4"> ' ;
463
+ } else {
464
+ print '<ul id="panel_container" class="container_col_3"> ' ;
465
+ }
462
466
463
467
if (cacti_sizeof ($ panels ) == 0 ) {
464
468
print '<table class="cactiTable"> ' ;
@@ -508,14 +512,15 @@ function display_information() {
508
512
509
513
// extra maint plugin panel - always first
510
514
if (api_plugin_is_enabled ('maint ' ) && (read_config_option ('intropage_maint_plugin_days_before ' ) >= 0 )) {
515
+
511
516
$ row = db_fetch_row_prepared ("SELECT id, data
512
517
FROM plugin_intropage_panel_data
513
518
WHERE panel_id = 'maint'
514
519
AND user_id = ? " ,
515
520
array ($ _SESSION ['sess_user_id ' ]));
516
521
517
- if ($ row && strlen ( $ row ['data ' ]) > 20 && $ dashboard_id == $ first_db ) {
518
- intropage_display_panel ($ row ['id ' ], $ dashboard_id );
522
+ if (isset ( $ row[ ' data ' ]) && $ row ['data ' ] != null && $ dashboard_id == $ first_db ) {
523
+ intropage_create_panel ($ row ['id ' ], $ dashboard_id );
519
524
}
520
525
}
521
526
// end of extra maint plugin panel
@@ -527,18 +532,18 @@ function display_information() {
527
532
WHERE panel_id='admin_alert' " );
528
533
529
534
if ($ id && $ dashboard_id == $ first_db ) {
530
- intropage_display_panel ($ id , $ dashboard_id );
535
+ intropage_create_panel ($ id , $ dashboard_id );
531
536
}
532
537
}
533
538
// end of admin panel
534
539
535
540
foreach ($ panels as $ xkey => $ xvalue ) {
536
- intropage_display_panel ($ xvalue ['id ' ], $ dashboard_id );
541
+ intropage_create_panel ($ xvalue ['id ' ], $ dashboard_id );
537
542
}
538
543
539
544
print '</ul> ' ;
540
545
print '<ul class="cloned-slides"></ul> ' ;
541
- print '</div> ' ; // end of megaobal
546
+ print '</div> ' ;
542
547
543
548
?>
544
549
<script type='text/javascript'>
0 commit comments