$difficulty = $value->difficulty; $profitability = $value->avgProfit; $price = $value->price; $priceusd = $price * $priceusd1; $priceeur = $price * $priceeur1; echo '<br>'; echo '-----'; echo '<br>'; echo $price; echo '<br>'; echo $shortname; echo '<br>'; echo $sname; echo '<br>'; echo $algo; echo '<br>'; echo $difficulty; echo '<br>'; echo $priceusd; echo '<br>'; echo $priceeur; echo '<br>'; echo $profitability; echo '<br>'; echo '-----'; echo '<br>'; echo '<br>'; insertcoin($shortname, $sname, $algo, $difficulty, $profitability, $price, $priceusd, $priceeur); error_reporting(E_ALL); } }
echo '<br>'; } } localmysqldbconnect(); $json = file_get_contents('http://www.coinchoose.com/api.php?base=BTC'); $result = json_decode($json); foreach ($result as $key => $value) { if ($value) { $minblocktime = $value->minBlockTime; $shortname = $value->symbol; $sname = $value->name; $algo = $value->algo; $difficulty = $value->difficulty; $price = $value->price; $priceusd = $price * $priceusd1; $priceeur = $price * $priceeur1; echo $price; echo '<br>'; echo $minblocktime; echo '<br>'; echo $shortname; echo '<br>'; echo $sname; echo '<br>'; echo $algo; echo '<br>'; echo $difficulty; insertcoin($shortname, $minblocktime, $sname, $algo, $difficulty, $price, $priceusd, $priceeur); error_reporting(E_ALL); } }