Index: html/includes/entities/mempool.inc.php =================================================================== --- html/includes/entities/mempool.inc.php (revision 7629) +++ html/includes/entities/mempool.inc.php (working copy) @@ -105,7 +105,6 @@ echo ' <thead>'; echo ' <tr>'; echo ' <th class="state-marker"></th>'; - echo ' <th style="width: 1px;"></th>'; if ($vars['page'] != "device") { echo ' <th style="width: 200px;">Device</th>'; @@ -172,8 +171,7 @@ $mempool['html_row_class'] = $background['class']; $row .= '<tr class="' . $mempool['html_row_class'] . '"> - <td class="state-marker"></td> - <td width="1px"></td>'; + <td class="state-marker"></td>'; if ($vars['page'] != "device" && $vars['popup'] != TRUE) { $row .= '<td class="entity">' . generate_device_link($mempool) . '</td>'; Index: html/includes/entities/port.inc.php =================================================================== --- html/includes/entities/port.inc.php (revision 7629) +++ html/includes/entities/port.inc.php (working copy) @@ -562,7 +562,7 @@ else if ($port['ifVrf']) // Print the VRF name if the port is assigned to a VRF { $vrf_name = dbFetchCell("SELECT `vrf_name` FROM `vrfs` WHERE `vrf_id` = ?", array($port['ifVrf'])); - $string .= '<br /><span class="small badge badge-success" data-rel="tooltip" data-tooltip="VRF">'.$vrf_name.'</span>'; + $string .= '<br /><span class="label label-success" data-rel="tooltip" data-tooltip="VRF">'.$vrf_name.'</span>'; } $string .= '</td>'; Index: html/includes/entities/processor.inc.php =================================================================== --- html/includes/entities/processor.inc.php (revision 7629) +++ html/includes/entities/processor.inc.php (working copy) @@ -93,7 +93,6 @@ echo(' <thead>'); echo(' <tr>'); echo(' <th class="state-marker"></th>'); - echo(' <th style="width: 1px;"></th>'); if ($vars['page'] != "device") { echo(' <th style="width: 200px;">Device</th>'); } echo(' <th>Processor</th>'); echo(' <th style="width: 100px;"></th>'); @@ -150,8 +149,7 @@ $processor['html_row_class'] = $background['class']; $row .= '<tr class="' . $processor['html_row_class'] . '"> - <td class="state-marker"></td> - <td width="1px"></td>'; + <td class="state-marker"></td>'; if ($vars['page'] != "device" && $vars['popup'] != TRUE) { $row .= '<td class="entity">' . generate_device_link($processor) . '</td>'; } Index: html/includes/entities/storage.inc.php =================================================================== --- html/includes/entities/storage.inc.php (revision 7629) +++ html/includes/entities/storage.inc.php (working copy) @@ -105,13 +105,12 @@ echo(' <thead>'); echo(' <tr>'); echo(' <th class="state-marker"></th>'); - echo(' <th style="width: 1px;"></th>'); if($vars['page'] != "device") { echo(' <th style="width: 250px;"><a href="'. generate_url($vars, array('sort' => 'hostname')).'">Device</a></th>'); } echo(' <th><a href="'. generate_url($vars, array('sort' => 'mountpoint')).'">Mountpoint</a></th>'); echo(' <th width="100"><a href="'. generate_url($vars, array('sort' => 'size')).'">Size</a></th>'); echo(' <th width="100"><a href="'. generate_url($vars, array('sort' => 'used')).'">Used</a></th>'); echo(' <th width="100"><a href="'. generate_url($vars, array('sort' => 'free')).'">Free</a></th>'); - echo(' <th width="100"</th>'); + echo(' <th width="100"></th>'); echo(' <th style="width: 200px;"><a href="'. generate_url($vars, array('sort' => 'usage')).'">Usage %</a></th>'); echo(' </tr>'); echo(' </thead>'); @@ -159,8 +158,7 @@ $storage['row_class'] = $background['class']; $row .= '<tr class="ports ' . $storage['row_class'] . '"> - <td class="state-marker"></td> - <td width="1px"></td>'; + <td class="state-marker"></td>'; if ($vars['page'] != "device" && $vars['popup'] != TRUE) { $row .= '<td class="entity">' . generate_device_link($storage) . '</td>'; } Index: html/includes/print/dot1xtable.inc.php =================================================================== --- html/includes/print/dot1xtable.inc.php (revision 7629) +++ html/includes/print/dot1xtable.inc.php (working copy) @@ -82,8 +82,10 @@ $list = array('device' => FALSE, 'port' => FALSE); // A radio is like a port if (!isset($vars['device']) || empty($vars['device']) || $vars['page'] == 'search') { $list['device'] = TRUE; } if (!isset($vars['port']) || empty($vars['port']) || $vars['page'] == 'search') { $list['port'] = TRUE; } - - $string = '<table class="table table-striped table-hover table-condensed">' . PHP_EOL; + + $string = generate_box_open(); + + $string .= '<table class="table table-striped table-hover table-condensed">' . PHP_EOL; if (!$short) { $string .= ' <thead>' . PHP_EOL; @@ -124,6 +126,8 @@ $string .= ' </tbody>' . PHP_EOL; $string .= '</table>'; + + $string .= generate_box_close(); // Print pagination header if ($pagination) { $string = pagination($vars, $count) . $string . pagination($vars, $count); } Index: html/includes/print/rows.inc.php =================================================================== --- html/includes/print/rows.inc.php (revision 7629) +++ html/includes/print/rows.inc.php (working copy) @@ -26,8 +26,8 @@ { $return .= ' <div class="box-header' . ($args['header-border'] ? ' with-border' : '') . '">'.PHP_EOL; if(isset($args['url'])) { $return .= '<a href="'.$args['url'].'">'; } - if(isset($args['icon'])) { $return .= '<i class="'.$args['icon'].'"></i> '; } - $return .= ' <h3 class="box-title">'; + if(isset($args['icon'])) { $return .= '<i class="'.$args['icon'].'"></i>'; } + $return .= '<h3 class="box-title">'; $return .= $args['title'].'</h3>'.PHP_EOL; if(isset($args['url'])) { $return .= '</a>'; } Index: html/pages/about.inc.php =================================================================== --- html/pages/about.inc.php (revision 7629) +++ html/pages/about.inc.php (working copy) @@ -63,7 +63,7 @@ </div> <div class="box box-solid"> - <div class="box-header"></i><h3 class="box-title">Statistics</h3></div> + <div class="box-header"><h3 class="box-title">Statistics</h3></div> <div class="box-body no-padding"> <?php Index: html/pages/alert_check.inc.php =================================================================== --- html/pages/alert_check.inc.php (revision 7629) +++ html/pages/alert_check.inc.php (working copy) @@ -142,7 +142,7 @@ <table class="' . OBS_CLASS_TABLE_STRIPED . '"> <thead> <tr> - <th style="width: 5%;">Test ID</th> + <!--<th style="width: 5%;">Test ID</th>--> <th style="width: 15%;">Entity Type</th> <th style="width: 20%;">Name</th> <th style="width: 45%;">Message</th> @@ -153,7 +153,7 @@ </thead> <tbody> <tr> - <td>' . $check['alert_test_id'] . '</td> + <!--<td>' . $check['alert_test_id'] . '</td>--> <td><i class="' . $config['entities'][$check['entity_type']]['icon'] . '"></i> ' . nicecase($check['entity_type']) . '</td> <td>' . escape_html($check['alert_name']) . '</td> <td><i>' . escape_html($check['alert_message']) . '</i></td> Index: html/pages/alert_regenerate.inc.php =================================================================== --- html/pages/alert_regenerate.inc.php (revision 7629) +++ html/pages/alert_regenerate.inc.php (working copy) @@ -22,14 +22,15 @@ // Regenerate alerts - echo '<div class="box box-solid">'; + echo generate_box_open(); + foreach (dbFetchRows("SELECT * FROM `devices`") as $device) { $result = update_device_alert_table($device); print_message($result['message'], $result['class']); } - echo '</div>'; + echo generate_box_close(); unset($vars['action']); Index: html/pages/bill/infoboxes.inc.php =================================================================== --- html/pages/bill/infoboxes.inc.php (revision 7629) +++ html/pages/bill/infoboxes.inc.php (working copy) @@ -33,7 +33,7 @@ $used = format_bytes_billing($total_data); $allowed = format_si($quota)."B"; $overuse = $total_data - $quota; - $overuse = (($overuse <= 0) ? "<span class=\"badge badge-success\">-</span>" : "<span class=\"badge badge-important\">".format_bytes_billing($overuse)."</span>"); + $overuse = (($overuse <= 0) ? "<span class=\"label label-success\">-</span>" : "<span class=\"label label-important\">".format_bytes_billing($overuse)."</span>"); $type = "Quota"; $imgtype = "&ave=yes"; $current = array( @@ -59,7 +59,7 @@ $used = format_si($rate_95th)."bps"; $allowed = format_si($cdr)."bps"; $overuse = $rate_95th - $cdr; - $overuse = (($overuse <= 0) ? "<span class=\"badge badge-success\">-</span>" : "<span class=\"badge badge-important\">".format_si($overuse)."bps</span>"); + $overuse = (($overuse <= 0) ? "<span class=\"label label-success\">-</span>" : "<span class=\"label label-important\">".format_si($overuse)."bps</span>"); $type = "CDR / 95th %"; $imgtype = "&95th=yes"; $current = array( @@ -148,8 +148,8 @@ </thead> <tr> <td style="width: 25%;"><span class="label label-inverse"><?php echo($type); ?></span></td> - <td style="width: 25%;"><span class="badge badge-success"><?php echo($allowed); ?></span></td> - <td><span class="badge badge-warning"><?php echo($used); ?></span></td> + <td style="width: 25%;"><span class="label label-success"><?php echo($allowed); ?></span></td> + <td><span class="label label-warning"><?php echo($used); ?></span></td> <td><?php echo($overuse); ?></td> </tr> </table> @@ -170,24 +170,24 @@ <th style="width: 125px;">Total</th> <?php } ?> - <td><span class="badge badge-success"><?php echo($current['in']); ?></span></td> - <td><span class="badge badge-info"><?php echo($current['out']); ?></span></td> - <td><span class="badge"><?php echo($current['tot']); ?></span></td> + <td><span class="label label-success"><?php echo($current['in']); ?></span></td> + <td><span class="label label-info"><?php echo($current['out']); ?></span></td> + <td><span class="label"><?php echo($current['tot']); ?></span></td> </tr> <tr> <th>Average</th> - <td><span class="badge badge-success"><?php echo($average['in']); ?></span></td> - <td><span class="badge badge-info"><?php echo($average['out']); ?></span></td> - <td><span class="badge"><?php echo($average['tot']); ?></span></td> + <td><span class="label label-success"><?php echo($average['in']); ?></span></td> + <td><span class="label label-info"><?php echo($average['out']); ?></span></td> + <td><span class="label"><?php echo($average['tot']); ?></span></td> </tr> <?php if ($bill_data['bill_type'] == "quota") { ?> <tr> <th>Estimated</th> - <td><span class="badge badge-success"><?php echo($estimated['in']); ?></span></td> - <td><span class="badge badge-info"><?php echo($estimated['out']); ?></span></td> - <td><span class="badge"><?php echo($estimated['tot']); ?></span></td> + <td><span class="label label-success"><?php echo($estimated['in']); ?></span></td> + <td><span class="label label-info"><?php echo($estimated['out']); ?></span></td> + <td><span class="label"><?php echo($estimated['tot']); ?></span></td> </tr> <?php } ?> <tr> Index: html/pages/customers.inc.php =================================================================== --- html/pages/customers.inc.php (revision 7629) +++ html/pages/customers.inc.php (working copy) @@ -12,9 +12,11 @@ */ $page_title[] = "Customers"; + +echo generate_box_open(); ?> -<table class="table table-hover table-striped-two table-condensed " style="margin-top: 10px;"> +<table class="table table-hover table-striped-two table-condensed "> <thead> <tr> <th style="width: 250px;"><span style="font-weight: bold;" class="interface">Customer</span></th> @@ -77,4 +79,6 @@ echo("</table>"); +echo generate_box_close(); + // EOF Index: html/pages/customoids.inc.php =================================================================== --- html/pages/customoids.inc.php (revision 7629) +++ html/pages/customoids.inc.php (working copy) @@ -84,7 +84,7 @@ echo ' <td><strong><a href="'.generate_url(array('page' => 'customoid', 'oid_id' => $oid['oid_id'])).'">'.$oid['oid_descr'].'</a></strong></td>'; echo ' <td>'.$oid['oid'].'</td>'; echo ' <td>'.$oid['oid_name'].'</td>'; - echo ' <td><span class="label label-'.($oid['oid_type'] == "GAUGE" ? "success" : "error").'">'.$oid['oid_type'].'</td>'; + echo ' <td><span class="label label-'.($oid['oid_type'] == "GAUGE" ? "success" : "error").'">'.$oid['oid_type'].'</span></td>'; echo ' <td>'.$oid['oid_unit'].'</td>'; echo ' <td><span class="label">'.$count.'</span></td>'; echo ' <td><a href="#customoid_del_modal_' . $oid['oid_id'] . '" data-toggle="modal"><i class="oicon-minus-circle"></i></a></td>'; Index: html/pages/deleted-ports.inc.php =================================================================== --- html/pages/deleted-ports.inc.php (revision 7629) +++ html/pages/deleted-ports.inc.php (working copy) @@ -32,6 +32,8 @@ } } +echo generate_box_open(); + echo('<table class="table table-condensed table-striped table-condensed"> <thead><tr> <th>Device</th> @@ -59,4 +61,6 @@ echo('</table>'); +echo generate_box_close(); + // EOF Index: html/pages/device.inc.php =================================================================== --- html/pages/device.inc.php (revision 7629) +++ html/pages/device.inc.php (working copy) @@ -436,7 +436,7 @@ // If the user has global write permissions, show them the edit tab if ($_SESSION['userlevel'] >= "10") { - $navbar['options']['tools'] = array('text' => '', 'icon' => 'oicon-gear', 'url' => '#', 'right' => TRUE, 'class' => "dropdown-toggle", 'link_opts' => 'data-hover="dropdown" data-toggle="dropdown"'); + $navbar['options']['tools'] = array('text' => '', 'icon' => 'oicon-gear', 'url' => '#', 'right' => TRUE, 'class' => "dropdown-toggle"); $navbar['options']['tools']['suboptions']['data'] = array('text' => 'Device Data', 'icon' => 'oicon-application-list'); $navbar['options']['tools']['suboptions']['perf'] = array('text' => 'Performance Data', 'icon' => 'oicon-time'); $navbar['options']['tools']['suboptions']['divider_1'] = array('divider' => TRUE); Index: html/pages/device/alerts.inc.php =================================================================== --- html/pages/device/alerts.inc.php (revision 7629) +++ html/pages/device/alerts.inc.php (working copy) @@ -99,10 +99,10 @@ if($vars['action'] == 'update') { - echo '<div class="box box-solid">'; + echo generate_box_open(); update_device_alert_table($device); $alert_table = cache_device_alert_table($device['device_id']); - echo '</div>'; + echo generate_box_close(); } $vars['pagination'] = TRUE; Index: html/pages/device/entphysical.inc.php =================================================================== --- html/pages/device/entphysical.inc.php (revision 7629) +++ html/pages/device/entphysical.inc.php (working copy) @@ -11,9 +11,9 @@ * */ -echo '<div class="box box-solid">'; +echo generate_box_open(); print_inventory($vars); -echo '</div>'; +echo generate_box_close(); $page_title[] = "Inventory"; Index: html/pages/device/health/diskio.inc.php =================================================================== --- html/pages/device/health/diskio.inc.php (revision 7629) +++ html/pages/device/health/diskio.inc.php (working copy) @@ -16,22 +16,19 @@ // Only show aggregate graph if we have access to the entire device. - echo generate_box_open(); - - echo('<table class="table table-condensed table-striped table-hover ">'); - - $graph_title = nicecase($vars['metric']); + $graph_title = nicecase($vars['metric']); $graph_array['type'] = "device_".$vars['metric']; $graph_array['device'] = $device['device_id']; $graph_array['legend'] = no; - echo('<tr><td>'); - echo('<h3>' . $graph_title . '</h3>'); + $box_args = array('title' => $graph_title, + 'header-border' => TRUE, + ); + + echo generate_box_open($box_args); + print_graph_row($graph_array); - echo('</td></tr>'); - echo('</table>'); - echo generate_box_close(); } Index: html/pages/device/health/mempool.inc.php =================================================================== --- html/pages/device/health/mempool.inc.php (revision 7629) +++ html/pages/device/health/mempool.inc.php (working copy) @@ -16,23 +16,20 @@ // Only show aggregate graph if we have access to the entire device. - echo '<div class="box box-solid">'; - - echo('<table class="table table-condensed table-striped table-hover ">'); - $graph_title = nicecase($vars['metric']); $graph_array['type'] = "device_".$vars['metric']; $graph_array['device'] = $device['device_id']; $graph_array['legend'] = no; - echo('<tr><td>'); - echo('<h3>' . $graph_title . '</h3>'); - print_graph_row($graph_array); - echo('</td></tr>'); + $box_args = array('title' => $graph_title, + 'header-border' => TRUE, + ); - echo('</table>'); + echo generate_box_open($box_args); - echo '</div>'; + print_graph_row($graph_array); + + echo generate_box_close(); } Index: html/pages/device/health/processor.inc.php =================================================================== --- html/pages/device/health/processor.inc.php (revision 7629) +++ html/pages/device/health/processor.inc.php (working copy) @@ -16,25 +16,22 @@ // Only show aggregate graph if we have access to the entire device. - echo '<div class="box box-solid">'; - - echo('<table class="table table-condensed table-striped table-hover ">'); - $graph_title = nicecase($vars['metric']); $graph_array['type'] = "device_".$vars['metric']; $graph_array['device'] = $device['device_id']; $graph_array['legend'] = no; - echo('<tr><td>'); - echo('<h3>' . $graph_title . '</h3>'); + $box_args = array('title' => $graph_title, + 'header-border' => TRUE, + ); + + echo generate_box_open($box_args); + print_graph_row($graph_array); - echo('</td></tr>'); - echo('</table>'); - $graph_type = "processor_usage"; - echo '</div>'; + echo generate_box_close(); } Index: html/pages/device/health/sensors.inc.php =================================================================== --- html/pages/device/health/sensors.inc.php (revision 7629) +++ html/pages/device/health/sensors.inc.php (working copy) @@ -16,25 +16,21 @@ // Don't show aggregate graphs to people without device permissions, or for "all sensors" view. - echo '<div class="box box-solid">'; - - - echo('<table class="table table-condensed table-striped table-hover">'); - $graph_title = nicecase($vars['metric']); $graph_array['type'] = "device_".$vars['metric']; $graph_array['device'] = $device['device_id']; $graph_array['legend'] = no; - echo('<tr><td>'); - echo('<h3>' . $graph_title . '</h3>'); + $box_args = array('title' => $graph_title, + 'header-border' => TRUE, + ); + + echo generate_box_open($box_args); + print_graph_row($graph_array); - echo('</td></tr>'); - echo('</table>'); + echo generate_box_close(); - echo '</div>'; - } print_sensor_table($vars); Index: html/pages/device/health/storage.inc.php =================================================================== --- html/pages/device/health/storage.inc.php (revision 7629) +++ html/pages/device/health/storage.inc.php (working copy) @@ -16,25 +16,22 @@ // Only show aggregate graph if we have access to the entire device. - echo '<div class="box box-solid">'; - - echo('<table class="table table-condensed table-striped table-hover ">'); - $graph_title = nicecase($vars['metric']); $graph_array['type'] = "device_".$vars['metric']; $graph_array['device'] = $device['device_id']; $graph_array['legend'] = no; - echo('<tr><td>'); - echo('<h3>' . $graph_title . '</h3>'); + $box_args = array('title' => $graph_title, + 'header-border' => TRUE, + ); + + echo generate_box_open($box_args); + print_graph_row($graph_array); - echo('</td></tr>'); - echo('</table>'); + echo generate_box_close(); - echo '</div>'; - } print_storage_table($vars); Index: html/pages/device/overview/c6kxbar.inc.php =================================================================== --- html/pages/device/overview/c6kxbar.inc.php (revision 7629) +++ html/pages/device/overview/c6kxbar.inc.php (working copy) @@ -11,16 +11,11 @@ * */ -?> +$box_args = array('title' => 'c6500/7600 Crossbar', + 'icon' => 'oicon-arrow-switch', + ); +echo generate_box_open($box_args); - <div class="box box-solid"> - <div class="box-header "> - <i class="oicon-arrow-switch"></i><h3 class="box-title">c6500/7600 Crossbar</h3> - </div> - <div class="box-body no-padding"> - -<?php - echo('<table class="table table-condensed table-striped">'); foreach ($entity_state['group']['c6kxbar'] as $index => $entry) @@ -108,6 +103,6 @@ } echo("</table>"); -echo("</div></div>"); +echo generate_box_close(); // EOF Index: html/pages/device/overview/information.inc.php =================================================================== --- html/pages/device/overview/information.inc.php (revision 7629) +++ html/pages/device/overview/information.inc.php (working copy) @@ -116,6 +116,6 @@ } echo("</table>"); -echo("</div></div>"); +echo generate_box_close(); // EOF Index: html/pages/device/overview/information_extended.inc.php =================================================================== --- html/pages/device/overview/information_extended.inc.php (revision 7629) +++ html/pages/device/overview/information_extended.inc.php (working copy) @@ -11,12 +11,8 @@ * */ -?> - <div class="box box-solid"> - <div class="box-body no-padding"> +echo generate_box_open(); -<?php - if ($device['os'] == "ios") { formatCiscoHardware($device); } // FIXME or do this in a general function for all OS types with a switch($device['os']) ? echo('<table class="table table-condensed table-striped table-hover">'); @@ -122,6 +118,6 @@ } echo("</table>"); -echo("</div></div>"); +echo generate_box_close(); // EOF Index: html/pages/device/overview/mempools.inc.php =================================================================== --- html/pages/device/overview/mempools.inc.php (revision 7629) +++ html/pages/device/overview/mempools.inc.php (working copy) @@ -21,17 +21,13 @@ $mempools = dbFetchRows($sql, array($device['device_id'])); if (count($mempools)) -{ ?> +{ + $box_args = array('title' => 'Memory', + 'url' => generate_url(array('page' => 'device', 'device' => $device['device_id'], 'tab' => 'health', 'metric' => 'mempool')), + 'icon' => 'oicon-memory', + ); + echo generate_box_open($box_args); - <div class="box box-solid"> - <div class="box-header "> - <a href="<?php echo(generate_url(array('page' => 'device', 'device' => $device['device_id'], 'tab' => 'health', 'metric' => 'mempool'))); ?>"> - <i class="oicon-memory"></i><h3 class="box-title">Memory</h3> - </a> - </div> - <div class="box-body no-padding"> - -<?php echo('<table class="table table-condensed table-striped">'); foreach ($mempools as $mempool) @@ -83,7 +79,7 @@ } echo("</table>"); - echo("</div></div>"); + echo generate_box_close(); } // EOF Index: html/pages/device/overview/processors-unix.inc.php =================================================================== --- html/pages/device/overview/processors-unix.inc.php (revision 7629) +++ html/pages/device/overview/processors-unix.inc.php (working copy) @@ -32,16 +32,13 @@ $processors[$text_descr]['usage'] += $proc['processor_usage']; $processors[$text_descr]['count']++; } -?> - <div class="box box-solid"> - <div class="box-header "> - <a href="<?php echo(generate_url(array('page' => 'device', 'device' => $device['device_id'], 'tab' => 'health', 'metric' => 'processor'))); ?>"> - <i class="oicon-processor"></i><h3 class="box-title">Processors</h3> - </a> - </div> - <div class="box-body no-padding"> -<?php + $box_args = array('title' => 'Processors', + 'url' => generate_url(array('page' => 'device', 'device' => $device['device_id'], 'tab' => 'health', 'metric' => 'processor')), + 'icon' => 'oicon-processor', + ); + echo generate_box_open($box_args); + $graph_array = array(); $graph_array['height'] = "100"; $graph_array['width'] = "512"; @@ -111,7 +108,7 @@ </tr>'); } echo("</table>"); - echo("</div></div>"); + echo generate_box_close(); } // EOF Index: html/pages/device/overview/processors.inc.php =================================================================== --- html/pages/device/overview/processors.inc.php (revision 7629) +++ html/pages/device/overview/processors.inc.php (working copy) @@ -32,17 +32,13 @@ $processors[$text_descr]['usage'] += $proc['processor_usage']; $processors[$text_descr]['count']++; } -?> - <div class="box box-solid"> - <div class="box-header "> - <a href="<?php echo(generate_url(array('page' => 'device', 'device' => $device['device_id'], 'tab' => 'health', 'metric' => 'processor'))); ?>"> - <i class="oicon-processor"></i><h3 class="box-title">Processors</h3> - </a> - </div> - <div class="box-body no-padding"> - -<?php + $box_args = array('title' => 'Processors', + 'url' => generate_url(array('page' => 'device', 'device' => $device['device_id'], 'tab' => 'health', 'metric' => 'processor')), + 'icon' => 'oicon-processor', + ); + echo generate_box_open($box_args); + echo('<table class="table table-condensed table-striped">'); foreach ($processors as $text_descr => $proc) @@ -85,7 +81,7 @@ } echo("</table>"); - echo("</div></div>"); + echo generate_box_close(); } // EOF Index: html/pages/device/overview/sensors.inc.php =================================================================== --- html/pages/device/overview/sensors.inc.php (revision 7629) +++ html/pages/device/overview/sensors.inc.php (working copy) @@ -39,18 +39,13 @@ { foreach ($sensors_db['measured'] as $measured_class => $measured_entity) { + $box_args = array('title' => nicecase($measured_class).' sensors', + 'icon' => 'oicon-node', + ); + echo generate_box_open($box_args); -?> + echo' <table class="table table-condensed table-striped">'; - <div class="box box-solid"> - <div class="box-header "> - <i class="oicon-node"></i> <h3 class="box-title"><?php echo(nicecase($measured_class)); ?> sensors</h3> - </div> - <div class="box-body no-padding"> - <table class="table table-condensed table-striped"> - -<?php - foreach ($measured_entity as $entity_id => $entry) { $entity = get_entity_by_id_cache($measured_class, $entity_id); @@ -78,10 +73,8 @@ ?> </table> - </div> - </div> <?php - + echo generate_box_close(); } // End for print bounds, unset this array unset($sensors_db['measured']); @@ -93,18 +86,12 @@ if (count($sensors)) { -?> + $box_args = array('title' => nicecase($sensor_type), + 'url' => generate_url(array('page' => 'device', 'device' => $device['device_id'], 'tab' => 'health', 'metric' => $sensor_type)), + 'icon' => $config['sensor_types'][$sensor_type]['icon'], + ); + echo generate_box_open($box_args); - <div class="box box-solid"> - <div class="box-header "> - <a href="<?php echo(generate_url(array('page' => 'device', 'device' => $device['device_id'], 'tab' => 'health', 'metric' => $sensor_type))); ?>"> - <i class="<?php echo($config['sensor_types'][$sensor_type]['icon']); ?>"></i><h3 class="box-title"><?php echo(nicecase($sensor_type)) ?></h3> - </a> - </div> - <div class="box-body no-padding"> - -<?php - echo('<table class="table table-condensed table-striped">'); foreach ($sensors as $sensor) { @@ -112,7 +99,7 @@ } echo("</table>"); - echo("</div></div>"); + echo generate_box_close(); } } Index: html/pages/device/overview/status.inc.php =================================================================== --- html/pages/device/overview/status.inc.php (revision 7629) +++ html/pages/device/overview/status.inc.php (working copy) @@ -19,18 +19,12 @@ if (count($status)) { -?> + $box_args = array('title' => 'Status Indicators', + 'url' => generate_url(array('page' => 'device', 'device' => $device['device_id'], 'tab' => 'health', 'metric' => 'status')), + 'icon' => $config['entities']['status']['icon'], + ); + echo generate_box_open($box_args); - <div class="box box-solid"> - <div class="box-header "> - <a href="<?php echo(generate_url(array('page' => 'device', 'device' => $device['device_id'], 'tab' => 'health', 'metric' => 'status'))); ?>"> - <i class="<?php echo($config['entities']['status']['icon']); ?>"></i><h3 class="box-title">Status Indicators</h3> - </a> - </div> - <div class="box-body no-padding"> - -<?php - echo('<table class="table table-condensed table-striped">'); foreach ($status as $status) { @@ -40,7 +34,7 @@ } echo("</table>"); - echo("</div></div>"); + echo generate_box_close(); } // EOF Index: html/pages/device/overview/storage.inc.php =================================================================== --- html/pages/device/overview/storage.inc.php (revision 7629) +++ html/pages/device/overview/storage.inc.php (working copy) @@ -23,17 +23,12 @@ { $drives = array_sort_by($drives, 'storage_descr', SORT_ASC, SORT_STRING); -?> + $box_args = array('title' => 'Storage', + 'url' => generate_url(array('page' => 'device', 'device' => $device['device_id'], 'tab' => 'health', 'metric' => 'storage')), + 'icon' => 'oicon-drive', + ); + echo generate_box_open($box_args); - <div class="box box-solid"> - <div class="box-header "> - <a href="<?php echo(generate_url(array('page' => 'device', 'device' => $device['device_id'], 'tab' => 'health', 'metric' => 'storage'))); ?>"> - <i class="oicon-drive"></i><h3 class="box-title">Storage</h3> - </a> - </div> - <div class="box-body no-padding"> - -<?php echo('<table class="table table-condensed table-striped">'); foreach ($drives as $drive) @@ -105,8 +100,7 @@ } echo("</table>"); - echo("</div>"); - echo("</div>"); + echo generate_box_close(); } unset ($drive_rows); Index: html/pages/device/overview/toner.inc.php =================================================================== --- html/pages/device/overview/toner.inc.php (revision 7629) +++ html/pages/device/overview/toner.inc.php (working copy) @@ -18,16 +18,12 @@ if (count($toners)) { -?> - <div class="box box-solid"> - <div class="box-header "> - <a href="<?php echo(generate_url(array('page' => 'device', 'device' => $device['device_id'], 'tab' => 'printing'))); ?>"> - <i class="oicon-contrast"></i><h3 class="box-title">Toner</h3> - </a> - </div> - <div class="box-body no-padding"> + $box_args = array('title' => 'Toner', + 'url' => generate_url(array('page' => 'device', 'device' => $device['device_id'], 'tab' => 'printing')), + 'icon' => 'oicon-contrast', + ); + echo generate_box_open($box_args); -<?php echo('<table class="table table-condensed table-striped">'); foreach ($toners as $toner) Index: html/pages/device/overview/ucd_mem.inc.php =================================================================== --- html/pages/device/overview/ucd_mem.inc.php (revision 7629) +++ html/pages/device/overview/ucd_mem.inc.php (working copy) @@ -11,16 +11,12 @@ * */ -?> - <div class="box box-solid"> - <div class="box-header "> - <a href="<?php echo(generate_url(array('page' => 'device', 'device' => $device['device_id'], 'tab' => 'health', 'metric' => 'mempool'))); ?>"> - <i class="oicon-memory"></i><h3 class="box-title">Memory</h3> - </a> - </div> - <div class="box-body no-padding"> +$box_args = array('title' => 'Memory', + 'url' => generate_url(array('page' => 'device', 'device' => $device['device_id'], 'tab' => 'health', 'metric' => 'mempool')), + 'icon' => 'oicon-memory', + ); +echo generate_box_open($box_args); -<?php $mem_used_total = $device_state['ucd_mem']['mem_total'] - $device_state['ucd_mem']['mem_avail']; $mem_used = $mem_used_total - ($device_state['ucd_mem']['mem_cached'] + $device_state['ucd_mem']['mem_buffer']); @@ -138,9 +134,8 @@ </table> - </div> - </div> - <?php +echo generate_box_close(); + // EOF Index: html/pages/device/port/vlans.inc.php =================================================================== --- html/pages/device/port/vlans.inc.php (revision 7629) +++ html/pages/device/port/vlans.inc.php (working copy) @@ -13,6 +13,8 @@ $vlans = dbFetchRows('SELECT * FROM `ports_vlans` AS PV, vlans AS V WHERE PV.`port_id` = ? and PV.`device_id` = ? AND V.`vlan_vlan` = PV.vlan AND V.device_id = PV.device_id', array($port['port_id'], $device['device_id'])); +echo generate_box_open(); + echo('<table class="table table-striped table-hover table-condensed">'); echo("<thead><tr><th>VLAN</th><th>Description</th><th>Cost</th><th>Priority</th><th>State</th><th>Other Ports</th></tr></thead>"); @@ -59,4 +61,6 @@ echo("</table>"); +echo generate_box_close(); + // EOF Index: html/pages/device/wifi/accesspoints.inc.php =================================================================== --- html/pages/device/wifi/accesspoints.inc.php (revision 7629) +++ html/pages/device/wifi/accesspoints.inc.php (working copy) @@ -26,7 +26,7 @@ $accesspoints = array_chunk($accesspoints, $vars['pagesize']); $accesspoints = $accesspoints[$vars['pageno']-1]; } - + echo generate_box_open(); echo('<table class="table table-hover table-condensed table-striped" style="vertical-align: middle; margin-top: 5px; margin-bottom: 10px;">'); echo('<thead><tr><th>Name</th><th>Model</th><th>Location</th><th>Serial/Fingerprint</th></tr></thead>'); @@ -41,6 +41,7 @@ } echo('</table>'); + echo generate_box_close(); echo(pagination($vars, $accesspoints_count)); } Index: html/pages/device/wifi/overview.inc.php =================================================================== --- html/pages/device/wifi/overview.inc.php (revision 7629) +++ html/pages/device/wifi/overview.inc.php (working copy) @@ -22,12 +22,14 @@ if (!in_array($radio['wifi_accesspoint_id'],$aps_ids)) $aps_ids[] = $radio['wifi_accesspoint_id']; } + echo generate_box_open(); echo('<table class="table table-striped table-condensed ">'); echo('<tr><td style="width: 350px;">'); echo("<span>" . count($aps_ids) . " APs</span><br /><span>" . count($radios) . " radios</span><br />"); echo('</td><td><span>Models: ' . implode(", ",$models) .'</span><br /><span>Sites: ' . implode(", ",$locations) . '</span></td>'); // echo('<td><span>'. $radios[0]['serial'] ." </span></br><span>" . $radios[0]['fingerprint']. "</span></td></tr>"); echo("</table>"); + echo generate_box_close(); } // EOF Index: html/pages/eventlog.inc.php =================================================================== --- html/pages/eventlog.inc.php (revision 7629) +++ html/pages/eventlog.inc.php (working copy) @@ -17,13 +17,6 @@ <?php -///FIXME. Mike: should be more checks, at least a confirmation click. -//if ($vars['action'] == "expunge" && $_SESSION['userlevel'] >= '10') -//{ -// dbFetchCell('TRUNCATE TABLE `eventlog`'); -// print_message('Event log truncated'); -//} - unset($search, $devices_array, $types); $where = ' WHERE 1 ' . generate_query_permitted(); Index: html/pages/front/default.php =================================================================== --- html/pages/front/default.php (revision 7629) +++ html/pages/front/default.php (working copy) @@ -333,7 +333,7 @@ { // Show Status - echo generate_box_open(array('title' => '<a href="/alerts/">Device Status Notifications</a>', 'header-border' => TRUE)); + echo generate_box_open(array('title' => 'Device Status Notifications', 'url' => '/alerts/', 'header-border' => TRUE)); print_status($config['frontpage']['device_status']); echo generate_box_close(); } // End show_status Index: html/pages/graphs.inc.php =================================================================== --- html/pages/graphs.inc.php (revision 7629) +++ html/pages/graphs.inc.php (working copy) @@ -67,7 +67,7 @@ ## Not all things here have a device (multiple-port graphs or location graphs) //if (!is_array($device)) //{ - // print_error('<h3 class="box-title">No valid device specified</h4> + // print_error('<h4>No valid device specified</h4> // A valid device was not specified in the URL. Please retype and try again.'); // break; //} @@ -472,9 +472,9 @@ echo generate_graph_js_state($graph_array); - echo('<div class="box box-solid">'); - echo(generate_graph_tag($graph_array)); - echo("</div>"); + echo generate_box_open(); + echo generate_graph_tag($graph_array); + echo generate_box_close(); if (isset($graph_return['descr'])) { @@ -493,46 +493,26 @@ if (isset($vars['showcommand'])) { -?> - - <div class="box box-solid"> - <div class="box-header with-border"> - <h3 class="box-title">Performance & Output</h3> - </div> - <div class="box-body"> - <?php echo("RRDTool Output: ".$return."<br />"); ?> - <?php echo("<p>Total time: ".$graph_return['total_time']." | RRDtool time: ".$graph_return['rrdtool_time']."s</p>"); ?> - </div> - </div> - - <div class="box box-solid"> - <div class="box-header with-border"> - <h3 class="box-title">RRDTool Command</h3> - </div> - <div class="box-body"> - <?php echo($graph_return['cmd']); ?> - </div> - </div> - - <div class="box box-solid"> - <div class="box-header with-border"> - <h3 class="box-title">RRDTool Files Used</h3> - </div> - <div class="box-body"> - <?php + echo generate_box_open(array('title' => 'Performance & Output', 'padding' => TRUE)); + echo("RRDTool Output: ".$return."<br />"); + echo("<p>Total time: ".$graph_return['total_time']." | RRDtool time: ".$graph_return['rrdtool_time']."s</p>"); + echo generate_box_close(); + + echo generate_box_open(array('title' => 'RRDTool Command', 'padding' => TRUE)); + echo $graph_return['cmd']; + echo generate_box_close(); + + echo generate_box_open(array('title' => 'RRDTool Files Used', 'padding' => TRUE)); if (is_array($graph_return['rrds'])) { foreach ($graph_return['rrds'] as $rrd) { - echo("$rrd <br />"); + echo "$rrd <br />"; } } else { - echo("No RRD information returned. This may be because the graph module doesn't yet return this data. <br />"); + echo "No RRD information returned. This may be because the graph module doesn't yet return this data. <br />"; } - ?> - </div> - </div> -<?php + echo generate_box_close(); } // EOF Index: html/pages/group.inc.php =================================================================== --- html/pages/group.inc.php (revision 7629) +++ html/pages/group.inc.php (working copy) @@ -131,7 +131,7 @@ <table class="table table-striped table-condensed "> <thead> <tr> - <th style="width: 5%;">ID</th> + <!--<th style="width: 5%;">ID</th>--> <th style="width: 25%;">Type</th> <th style="width: 60%;">Group</th> <th style="width: 15%;">Members</th> @@ -139,7 +139,7 @@ </thead> <tbody> <tr> - <td>', $group['group_id'], '</td> + <!--<td>', $group['group_id'], '</td>--> <td><i class="', $entity_type['icon'], '"></i> ', nicecase($group['entity_type']), '</td> <td><strong>', escape_html($group['group_name']), '</strong><br /><i>', escape_html($group['group_descr']), '</i></td> <td><span class="label" style="float:right;">', $group['member_count'], '</span></td> @@ -176,7 +176,7 @@ <tr> <th style="width: 45%;">Device Match</th> <th style="">Entity Match</th> - <th style="width: 10%;"></th> + <th style="width: 12%;"></th> </tr> </thead> @@ -224,21 +224,24 @@ echo '</code></td>'; echo ' <td style="text-align: right;">'; - if ($_SESSION['userlevel'] == 10) { + if ($_SESSION['userlevel'] == 10) + { echo ' <a href="#assoc_modal_' . $assoc['group_assoc_id'] . '" data-toggle="modal"><i class="icon-cog text-muted"></i></a> - <a href="#assoc_del_modal_' . $assoc['group_assoc_id'] . '" data-toggle="modal"><i class="icon-trash text-danger"></i></a></td>'; + <a href="#assoc_del_modal_' . $assoc['group_assoc_id'] . '" data-toggle="modal"><i class="icon-trash text-danger"></i></a>'; } + echo '</td>'; + echo '</tr>'; + // Print associations edit modal for this association. -?> - -<div id="assoc_del_modal_<?php echo $assoc['group_assoc_id']; ?>" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="delete_group" aria-hidden="true"> +$modals .= ' +<div id="assoc_del_modal_'.$assoc['group_assoc_id'].'" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="delete_group" aria-hidden="true"> <form id="edit" name="edit" method="post" class="form" action=""> - <input type="hidden" name="assoc_id" value="<?php echo $assoc['group_assoc_id']; ?>"> + <input type="hidden" name="assoc_id" value="'.$assoc['group_assoc_id'].'"> <div class="modal-header"> <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button> - <h3 id="myModalLabel"><i class="icon-minus-circle"></i> Delete Assocation Rule <?php echo($assoc['group_assoc_id']); ?></h3> + <h3 id="myModalLabel">Delete Assocation Rule '.$assoc['group_assoc_id'].'</h3> </div> <div class="modal-body"> @@ -250,13 +253,13 @@ </label> <div class="controls"> <label class="checkbox"> - <input type="checkbox" name="confirm" value="confirm" onchange="javascript: showWarning<?php echo $assoc['group_assoc_id']; ?>(this.checked);" /> + <input type="checkbox" name="confirm" value="confirm" onchange="javascript: showWarning'.$assoc['group_assoc_id'].'(this.checked);" /> Yes, please delete this association rule! </label> <script type="text/javascript"> - function showWarning<?php echo $assoc['group_assoc_id']; ?>(checked) { - if (checked) { $('#delete_button<?php echo $assoc['group_assoc_id']; ?>').removeAttr('disabled'); } else { $('#delete_button<?php echo $assoc['group_assoc_id']; ?>').attr('disabled', 'disabled'); } + function showWarning'.$assoc['group_assoc_id'].'(checked) { + if (checked) { $(\'#delete_button'.$assoc['group_assoc_id'].'\').removeAttr(\'disabled\'); } else { $(\'#delete_button'.$assoc['group_assoc_id'].'\').attr(\'disabled\', \'disabled\'); } } </script> </div> @@ -270,34 +273,36 @@ </div> <div class="modal-footer"> <button class="btn" data-dismiss="modal" aria-hidden="true">Close</button> - <button id="delete_button<?php echo $assoc['group_assoc_id']; ?>" type="submit" class="btn btn-danger" name="submit" value="delete_assoc" disabled><i class="icon-trash icon-white"></i> Delete Association</button> + <button id="delete_button'.$assoc['group_assoc_id'].'" type="submit" class="btn btn-danger" name="submit" value="delete_assoc" disabled><i class="icon-trash icon-white"></i> Delete Association</button> </div> </form> </div> +'; -<div id="assoc_modal_<?php echo $assoc['group_assoc_id']; ?>" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true"> +$modals .= ' +<div id="assoc_modal_'.$assoc['group_assoc_id'].'" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true"> <form id="edit" name="edit" method="post" class="form" action=""> <div class="modal-header"> <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button> - <h3 id="myModalLabel"><i class="oicon-sql-join-inner"></i> Edit Association Conditions</h3> + <h3 id="myModalLabel">Edit Association Conditions</h3> </div> <div class="modal-body"> - <input type="hidden" name="assoc_id" value="<?php echo $assoc['group_assoc_id']; ?>"> + <input type="hidden" name="assoc_id" value="'.$assoc['group_assoc_id'].'"> <span class="help-block">Please exercise care when editing here.</span> <fieldset> <div class="control-group"> <label>Device match</label> <div class="controls"> - <textarea class="col-sm-12" rows="4" name="assoc_device_conditions"><?php echo(escape_html(implode("\n", $assoc_dev_text))); ?></textarea> + <textarea class="col-sm-12" rows="4" name="assoc_device_conditions">'.escape_html(implode("\n", $assoc_dev_text)).'</textarea> </div> </div> <div class="control-group"> <label>Entity match</label> <div class="controls"> - <textarea class="col-sm-12" rows="4" name="assoc_entity_conditions"><?php echo(escape_html(implode("\n", $assoc_entity_text))); ?></textarea> + <textarea class="col-sm-12" rows="4" name="assoc_entity_conditions">'.escape_html(implode("\n", $assoc_entity_text)).'</textarea> </div> </div> </fieldset> @@ -309,10 +314,8 @@ </div> </form> </div> +'; -<?php - - echo '</tr>'; } // End Edit Assoc echo ' </table>'; @@ -320,6 +323,8 @@ echo ' </div>'; echo ' </div>'; echo '</div>'; + + echo $modals; $members = dbFetchRows("SELECT * FROM `group_table` WHERE `group_id` = ?", array($vars['group_id'])); foreach ($members as $member) { $member_ids[] = $member['entity_id']; } @@ -413,13 +418,9 @@ $graph_array['id'] = implode($memberlist, ','); $graph_array['type'] = 'multi-'.$group['entity_type'].'_'.$vars['agg_graph']; - echo '<div class="box box-solid"> - <div class="box-header">'; - - echo '<h3 class="box-title">Aggregate '.$config['entities'][$group['entity_type']]['agg_graphs'][$vars['agg_graph']]['name'].'</h3>'; - echo '</div>'; + echo generate_box_open(array('title' => 'Aggregate '.$config['entities'][$group['entity_type']]['agg_graphs'][$vars['agg_graph']]['name'])); print_graph_row($graph_array); - echo '</div>'; + echo generate_box_close(); } @@ -427,10 +428,9 @@ { case "port": - + echo pagination($vars, $group['member_count']); echo generate_box_open(); echo '<table class="table table-condensed table-striped table-hover">'; - echo pagination($vars, $group['member_count']); if ($vars['pageno']) { @@ -577,7 +577,7 @@ <div class="modal-header"> <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button> - <h3 id="myModalLabel"><i class="oicon-minus-circle"></i> Delete Group <?php echo(escape_html($group['group_name'])); ?></h3> + <h3 id="myModalLabel">Delete Group <?php echo(escape_html($group['group_name'])); ?></h3> </div> <div class="modal-body"> @@ -626,7 +626,7 @@ <form id="add_assoc" name="add_assoc" method="post" class="form" action=""> <div class="modal-header"> <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button> - <h3 id="add_assoc_label"><i class="oicon-sql-join-inner"></i> Add Association Conditions</h3> + <h3 id="add_assoc_label">Add Association Conditions</h3> </div> <div class="modal-body"> @@ -664,7 +664,7 @@ <form id="edit" name="edit" method="post" class="form" action=""> <div class="modal-header"> <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button> - <h3 id="myModalLabel"><i class="oicon-sql-join-inner"></i> Edit Group Details</h3> + <h3 id="myModalLabel">Edit Group Details</h3> </div> <div class="modal-body"> Index: html/pages/group_add.inc.php =================================================================== --- html/pages/group_add.inc.php (revision 7629) +++ html/pages/group_add.inc.php (working copy) @@ -102,7 +102,7 @@ $form = array('type' => 'horizontal', 'id' => 'edit', //'space' => '20px', - 'title' => 'New Group', + //'title' => 'New Group', //'icon' => 'oicon-gear', ); // top row div Index: html/pages/groups_regenerate.inc.php =================================================================== --- html/pages/groups_regenerate.inc.php (revision 7629) +++ html/pages/groups_regenerate.inc.php (working copy) @@ -11,8 +11,6 @@ * */ -include($config['html_dir']."/includes/alerting-groups.inc.php"); - // Global write permissions required. if ($_SESSION['userlevel'] < 10) { @@ -20,16 +18,19 @@ return; } - // Regenerate alerts +include($config['html_dir']."/includes/alerting-groups.inc.php"); - echo '<div class="box box-solid">'; - foreach (dbFetchRows("SELECT * FROM `devices`") AS $device) -// foreach (dbFetchRows("SELECT * FROM `devices` WHERE device_id = 335") AS $device) + // Regenerate groups + + echo generate_box_open(); + + foreach (dbFetchRows("SELECT * FROM `devices`") as $device) +// foreach (dbFetchRows("SELECT * FROM `devices` WHERE device_id = 335") as $device) { update_device_group_table($device); } - echo '</div>'; + echo generate_box_close(); unset($vars['action']); Index: html/pages/locations.inc.php =================================================================== --- html/pages/locations.inc.php (revision 7629) +++ html/pages/locations.inc.php (working copy) @@ -36,7 +36,7 @@ $cols = array( array(NULL, 'class="state-marker"'), 'location' => array('Location', 'style="width: 300px;"'), - 'total' => array('Devices: Total', 'style="width: 50px; text-align: right;"') + 'total' => array('Devices: Total', 'style="width: 50px; text-align: right;"') ); foreach (array_keys($cache['device_types']) as $type) Index: html/pages/settings/default.inc.php =================================================================== --- html/pages/settings/default.inc.php (revision 7629) +++ html/pages/settings/default.inc.php (working copy) @@ -42,19 +42,13 @@ if ($vars['section'] == 'all') { // When printing all, also print the section name - echo(' <div class="box box-solid"><div class="box-header"><h3 class="box-title">' . $config_sections[$section]['text'] . '</h3></div></div>' . PHP_EOL); + echo generate_box_open(array('title' => $config_sections[$section]['text'], 'header-border' => TRUE)); + echo generate_box_close(); } foreach ($subdata as $subsection => $vardata) { - echo '<div class="box box-solid">'; - - // Print subsection name - echo('<div class="box-header with-border">' . PHP_EOL); - echo(' <h3 class="box-title">' . $subsection . '</h3>' . PHP_EOL); - echo('</div>' . PHP_EOL); - - echo('<div class="box-content no-padding">' . PHP_EOL); + echo generate_box_open(array('title' => $subsection, 'header-border' => TRUE)); echo(' <table class="table table-striped table-condensed" style="">' . PHP_EOL); $cols = array( @@ -264,9 +258,7 @@ } echo(' </table>' . PHP_EOL); - echo '</div>'; - echo '</div>'; - + echo generate_box_close(); } //echo(' <br />' . PHP_EOL); } Index: includes/common.inc.php =================================================================== --- includes/common.inc.php (revision 7629) +++ includes/common.inc.php (working copy) @@ -510,13 +510,9 @@ } else { $http_version = str_replace("Apache/", "", $_SERVER['SERVER_SOFTWARE']); $observium_date = format_unixtime(strtotime(OBSERVIUM_DATE), 'jS F Y'); - + + echo generate_box_open(array('title' => 'Version Information')); echo(' - <div class="box box-solid"> - <div class="box-header"> - <h3 class="box-title">Version Information</h3> - </div> - <div class="box-content"> <table class="table table-striped table-condensed-more"> <tbody> <tr><td><b>'.escape_html(OBSERVIUM_PRODUCT).'</b></td><td>'.escape_html(OBSERVIUM_VERSION).' ('.escape_html($observium_date).')</td></tr> @@ -528,9 +524,8 @@ <tr><td><b>SNMP</b></td><td>'.escape_html($snmp_version).'</td></tr> <tr><td><b>RRDtool</b></td><td>'.escape_html($rrdtool_version).'</td></tr> </tbody> - </table> - </div> - </div>'.PHP_EOL); + </table>'.PHP_EOL); + echo generate_box_close(); } }