1 <?php
defined('SYSPATH') OR die('No direct access allowed.'); ?
>
2 <table summary
="Network health" class="health" style
="table-layout:fixed;">
4 <?php
foreach( $bars as $bar ):
5 if ($bar['value'] < $this->health_critical_percentage
) {
6 $image = $this->widget_full_path
.$this->crit_img
;
7 } else if ($bar['value'] < $this->health_warning_percentage
) {
8 $image = $this->widget_full_path
.$this->warn_img
;
10 $image = $this->widget_full_path
.$this->ok_img
;
13 <td style
="text-align: center;">
14 <div style
="<?php echo ($bar['value'] > 33) ? 'color: #ffffff;' : ''?>font-size: 140%; position: absolute; padding-top: 62px; padding-left: 10px;"><?php
echo round($bar['value'],$visible_precision) ?
> %
</div
>
15 <div style
="<?php echo ($bar['value'] > 12) ? 'color: #ffffff;' : ''?>font-size: 90%; position: absolute; padding-top: 84px; padding-left: 10px;"><?php
echo $bar['label'] ?
></div
>
17 <?php
echo html
::image($image, array('style' => 'height:'.round($bar['value']).'px; width: 100%; padding-top: '.(100-round($bar['value'])).'px', 'alt' => $bar['label'])) ?
>