Now for the Total Hash Rate of the Pool:
1. SQL insert
ALTER TABLE `stats_poolMHashHistory` ADD `totalMhash` INT( 50 ) NOT NULL
replace:
//Get average Mhash for the entire pool
$poolAverageHashQ = mysql_query("SELECT `mhashes` FROM `stats_userMHashHistory` WHERE `mhashes` > 0 AND `timestamp` = '".$globalTime."'");
$numPoolHashRows = mysql_num_rows($poolAverageHashQ);
$averagePoolHash = 0;
while($poolHash = mysql_fetch_array($poolAverageHashQ)){
$averagePoolHash += $poolHash["mhashes"];
}
if($averagePoolHash > 0 && $numPoolHashRows > 0){
$averagePoolHash = $averagePoolHash/$numPoolHashRows;
}
//Add pool average to table
mysql_query("INSERT INTO `stats_poolMHashHistory` (`timestamp`, `averageMhash`)
VALUES('$globalTime', '$averagePoolHash')");
//Get average and total Mhash for the entire pool
$poolAverageHashQ = mysql_query("SELECT `mhashes` FROM `stats_userMHashHistory` WHERE `mhashes` > 0 AND `timestamp` = '".$globalTime."'");
$numPoolHashRows = mysql_num_rows($poolAverageHashQ);
$averagePoolHash = 0;
$totalPoolHash = 0;
while($poolHash = mysql_fetch_array($poolAverageHashQ)){
$averagePoolHash += $poolHash["mhashes"];
$totalPoolHash += $poolHash["mhashes"];
}
if($averagePoolHash > 0 && $numPoolHashRows > 0){
$averagePoolHash = $averagePoolHash/$numPoolHashRows;
}
//Add pool average and total to table
mysql_query("INSERT INTO `stats_poolMHashHistory` (`timestamp`, `averageMhash`, `totalMhash`)
VALUES('$globalTime', '$averagePoolHash', '$totalPoolHash')");
save.
3. open index.php
and replace it with this one:
http://nopaste.info/46f62a7fde_nl.html
4. Looks like that:
http://imageshack.us/photo/my-images/864/chartz.png/