|
$label: |
|
ENDROW;
}
$remote = $_SERVER["REMOTE_ADDR"];
echo <<
Since some of you did not seem greatly enlightened
by our last histogram, we have provided a prettier one.
END;
// This generates the table, and takes a total of the parts. The foreach
// explodes the address into parts, then goes through the parts.
echo "
\n";
$tot = 0;
foreach (explode('.', $remote) as $comp) {
bar($comp, $comp);
$tot += $comp;
}
// Compute the average, then generate a bar for it, after creating some
// blank space.
$av = $tot/4;
echo " |
\n";
bar("Average ($av)", $av);
echo "
\n";
?>