99999999) $b4 = ''; else if ($num > 9999999) $b4 = ''; if ($b4 != '') $af = ''; return $b4.$fmt.$af; } # function dopplns($data, $user) { global $send_sep; $pg = '

CKPool

'; $blk = getparam('blk', true); if (nuem($blk)) { $pg = "
Block:  
"; } else { $msg = msgEncode('pplns', 'pplns', array('height' => $blk, 'allow_aged' => 'Y')); $rep = sendsockreply('pplns', $msg); if ($rep == false) $ans = array(); else $ans = repDecode($rep); if ($ans['ERROR'] != null) return '
'.$ans['STATUS'].': '.$ans['ERROR'].'
'; $data = array( 'Block' => 'block', 'PPLNS Wanted' => 'diff_want', 'PPLNS Used' => 'diffacc_total', 'Elapsed Seconds' => 'pplns_elapsed', 'Users' => 'rows', 'Oldest Workinfoid' => 'begin_workinfoid', 'Oldest Time' => 'begin_stamp', 'Block Workinfoid' => 'block_workinfoid', 'Block Time' => 'block_stamp', 'Newest Workinfoid' => 'end_workinfoid', 'Newest Time' => 'end_stamp', 'Network Difficulty' => 'block_ndiff', 'PPLNS Factor' => 'diff_times', 'PPLNS Added' => 'diff_add', 'Share Count' => 'share_count'); $pg = "
\n"; $pg .= ''; $pg .= ''; $pg .= ''; $pg .= "\n"; $i = 0; foreach ($data as $dsp => $name) { if (($i++ % 2) == 0) $row = 'even'; else $row = 'odd'; $pg .= ""; $pg .= ""; $pg .= ''; $pg .= "\n"; } $pg .= "
NameValue
$dsp'.$ans[$name].'

\n"; $pg .= ''; $pg .= ''; $pg .= ''; $pg .= "\n"; $count = $ans['rows']; for ($i = 1; $i <= $count; $i++) { if (($i % 2) == 0) $row = 'even'; else $row = 'odd'; $pg .= ""; $pg .= ''; $pg .= ''; $pg .= "\n"; } $pg .= "
UserDiff Accepted
'.$ans['user'.$i].''.$ans['diffacc_user'.$i].'
\n"; } return $pg; } # function show_pplns($menu, $name, $user) { gopage(NULL, 'dopplns', $menu, $name, $user); } # ?>