| 2 |  |  | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 3 |  | # | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 4 |  | # i-scream central monitoring system | 
 
 
 
 
 
 
 
 | 5 | + | # http://www.i-scream.org.uk | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 6 |  | # Copyright (C) 2000-2002 i-scream | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 7 |  | # | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 8 |  | # This program is free software; you can redistribute it and/or | 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 | 110 |  | if (!is_int($max)) { | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 111 |  | $max = getPregMatch($max, $input); | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 112 |  | } | 
 
 
 
 
 
 
 
 
 
 
 | 113 | < | if (!isset($value) || empty($max)) { | 
 
 
 
 
 
 
 
 
 | 113 | > | if (!isset($value) || !isset($max)) { | 
 
 
 
 
 
 
 
 
 
 
 | 114 |  | return; | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 115 |  | } | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 116 |  |  | 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 | 118 |  | $value = $max - $value; | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 119 |  | } | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 120 |  |  | 
 
 
 
 
 
 
 
 
 
 
 | 121 | < | $width = intval($max_width * $value / $max); | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 121 | < |  | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 122 | < | if ($width < 1) { | 
 
 
 
 
 
 
 
 
 | 121 | > | if(empty($max)) { | 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 | 122 |  | $width = 1; | 
 
 
 
 
 
 
 
 | 123 | + | } | 
 
 
 
 
 
 
 
 | 124 | + | else { | 
 
 
 
 
 
 
 
 | 125 | + | $width = intval($max_width * $value / $max); | 
 
 
 
 
 
 
 
 | 126 | + | if ($width < 1) { | 
 
 
 
 
 
 
 
 | 127 | + | $width = 1; | 
 
 
 
 
 
 
 
 | 128 | + | } | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 129 |  | } | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 130 |  |  | 
 
 
 
 
 
 
 
 
 
 
 
 
 | 131 |  | ?> |