Advertisement
lnt900

utcnitro.php

Feb 10th, 2014
96
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.74 KB | None | 0 0
  1. <?
  2. $apikey = 'apikeyhere';
  3. $xx = 'http://ultra.nitro.org/index.php?page=api&action=getuserstatus&api_key='.$apikey;
  4. $yy = 'http://ultra.nitro.org/index.php?page=api&action=getuserbalance&api_key='.$apikey;
  5. $zz = 'http://ultra.nitro.org/index.php?page=api&action=getuserworkers&api_key='.$apikey;
  6. $xz = 'http://ultra.nitro.org/index.php?page=api&action=getusertransactions&api_key='.$apikey;
  7. $coin_name = 'UTC';
  8. $json =  file_get_contents($xx);
  9. $json1 = file_get_contents($yy);
  10. $json2 = file_get_contents($zz);
  11.  
  12. $nfo1 = json_decode($json,true);
  13. $nfo2 = json_decode($json1,true);
  14. $nfo3 = json_decode($json2,true);
  15.  
  16.  
  17. echo '<meta http-equiv="refresh" content="600">';
  18. echo "\r\nBalance : <font color= 'blue'><b>".$nfo2["getuserbalance"]["data"]["confirmed"]." $coin_name</b></font></br>\r\n";
  19. echo "\r\nNot Cofirmed Balance : <font color= 'red'><b>".$nfo2["getuserbalance"]["data"]["unconfirmed"]." $coin_name</b></font></br>\r\n";
  20. echo "Total hashrate : <font color= 'green'><b>".$nfo1["getuserstatus"]["data"]["hashrate"]." KH/s</b></font></br>\r\n";
  21. echo "Sharerate : <font color= 'green'><b>".$nfo1["getuserstatus"]["data"]["sharerate"]." S/s</b></font></br>\r\n";
  22. echo "Unpaid shares : <b>".$nfo1["getuserstatus"]["data"]["shares"]["valid"]."</b></br>\r\n";
  23. //echo "Round estimate : $nfo[round_estimate] $coin_name</br>\r\n";
  24. //echo "Payout history : $nfo[payout_history]</br>\r\n";
  25. $wks = $nfo3["getuserworkers"]["data"];
  26.  
  27. while ($worker = current($wks)) {
  28.     if($worker["hashrate"] > 0){
  29.         $wknfo = "is online - hashrate : <b>$worker[hashrate] KH/s</b>";
  30.         $color = "green";
  31.     } else {
  32.         $wknfo = "is offline";
  33.         $color = "red";
  34.     }
  35.     echo "<font color= '$color'>Worker <b>". $worker[username]."</b> $wknfo</font><br />\r\n";
  36.     next($wks);
  37. }
  38. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement