Bitcoin monitors

So, in an effort of procrastination in regards of some coursework, I decided to take a look at my bitcoin pooled miner monitor thing, to see if all was well.

Turns out that BTCguild has changed their API since I last looked (quite some time) and that it had gone HTTPS. Now, the API change isn’t that much of a problem, except figuring out what all this new info means, but the HTTPS problem is that I couldn’t just use file_get_contents() because of some limitations on my main hosting service.

After trying to find a way around it by using other methods and such, I figured the easiest (and ugliest) way was to put a page somewhere else that would be able to execute the file_get_contents(). That didn’t last long, since I found out how to do it with cURL:

 function fetchUrl($url) {
 $data = curl_exec($ch);
 return $data;

It does take a bit longer to load the page, but at least it works right and is better than using another page elsewhere.

If you would like to see how all that works (provided you have an account on one of the supported pools) you can check out

This entry was posted in Bitcoin, WebDev and tagged , , , , . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *