|
|
@ -131,12 +131,21 @@ function pgtop($dotop, $user, $douser) |
|
|
|
{ |
|
|
|
{ |
|
|
|
$now = time(); |
|
|
|
$now = time(); |
|
|
|
|
|
|
|
|
|
|
|
if (isset($info['PoolHashRate'])) |
|
|
|
if (isset($info['p_hashrate5m'])) |
|
|
|
$phr = $info['PoolHashRate'].'TH/s'; |
|
|
|
{ |
|
|
|
|
|
|
|
$phr = $info['p_hashrate5m']; |
|
|
|
|
|
|
|
if ($phr == '?') |
|
|
|
|
|
|
|
$phr .= 'THs'; |
|
|
|
|
|
|
|
else |
|
|
|
|
|
|
|
$phr = (round($phr/10)/100).'THs'; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if (isset($info['PoolLastBlock'])) |
|
|
|
if (isset($info['lastblock'])) |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
$plb = $info['lastblock']; |
|
|
|
|
|
|
|
if ($plb != '?') |
|
|
|
{ |
|
|
|
{ |
|
|
|
$sec = $now - $info['PoolLastBlock']; |
|
|
|
$sec = $now - $plb; |
|
|
|
if ($sec < 60) |
|
|
|
if ($sec < 60) |
|
|
|
$plb = $sec.'s'; |
|
|
|
$plb = $sec.'s'; |
|
|
|
else |
|
|
|
else |
|
|
@ -156,23 +165,35 @@ function pgtop($dotop, $user, $douser) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if (isset($info['NetLastBlock'])) |
|
|
|
if (isset($info['lastlp'])) |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
$nlb = $info['lastlp']; |
|
|
|
|
|
|
|
if ($nlb != '?') |
|
|
|
{ |
|
|
|
{ |
|
|
|
$sec = $now - $info['NetLastBlock']; |
|
|
|
$sec = $now - $info['lastlp']; |
|
|
|
$min = round($sec / 60); |
|
|
|
$min = round($sec / 60); |
|
|
|
$nlb = $min.'m'; |
|
|
|
$nlb = $min.'m'; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if (isset($info['UserHashRate'])) |
|
|
|
if (isset($info['u_hashrate5m'])) |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
$uhr = $info['u_hashrate5m']; |
|
|
|
|
|
|
|
if ($uhr == '?') |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
$uhr .= 'GHs'; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
else |
|
|
|
{ |
|
|
|
{ |
|
|
|
$uhr = $info['UserHashRate']; |
|
|
|
|
|
|
|
if ($uhr < 1000) |
|
|
|
if ($uhr < 1000) |
|
|
|
$uhr .= 'GHs'; |
|
|
|
$uhr .= 'GHs'; |
|
|
|
else |
|
|
|
else |
|
|
|
$uhr = (round($uhr/10)/100).'THs'; |
|
|
|
$uhr = (round($uhr/10)/100).'THs'; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
addscript("function jst(){document.getElementById('jst').style.visibility='hidden';}"); |
|
|
|
addscript("function jst(){document.getElementById('jst').style.visibility='hidden';}"); |
|
|
|
$top = "<div class=jst id=jst> Javascript isn't enabled."; |
|
|
|
$top = "<div class=jst id=jst> Javascript isn't enabled."; |
|
|
|