Author

Topic: [HTML] Display current bitcoin price - Help?! (Read 5569 times)

sr. member
Activity: 412
Merit: 250
will try this, thank you
sr. member
Activity: 412
Merit: 250
Problem will be then, that you have to understand the code of the forum software you are using.


I use phpbb3 and I understand how to use BBCode
legendary
Activity: 965
Merit: 1000
Problem will be then, that you have to understand the code of the forum software you are using.
sr. member
Activity: 412
Merit: 250

Thanks I already try that.
I am trying to get those data on forum on portal page with as custom block
but not working.

I also am trying to get those data by BBCode for forum... also didn't manage to work

but have no knowledge of php or html...
sr. member
Activity: 412
Merit: 250
can someone help me pull data from this site in html?
withouth commas and quotes
https://api.bitcoinaverage.com/ticker/global/AED


and this one
https://api.bitcoinaverage.com/ticker/global/USD/last
member
Activity: 84
Merit: 10
www.coincloud.tk :)
Thank you for all the help guys!
The last post is the one I had in mind - I had came across that site before and lost it!

THAAAAAAAAANK YOOOOOOOOOOOOOOOU!  Grin Cheesy

I'll send everyone who pitched in some code a little donation if you pm me your address Smiley
sr. member
Activity: 287
Merit: 250
Not sure if you are still in need, but I just came across this image widget:



You can just add an image with this link to the site:

https://btcticker.appspot.com/mtgox/1.00btc.png

and it will display the current price in USD.

I don't know how reliable this widget is though.
member
Activity: 62
Merit: 10
This probably isn't exactly what you're looking for but it does show the current (USD) price and also a poll for whether you think the price will be up, down or neutral over the next 6 months.

http://bitcoinsentiment.com/?id=1026

It's a great project and has the potential to be a really useful trading indicator - and the more people use it the better it gets.

The widget code is:

Code:
member
Activity: 99
Merit: 10
Two pages, you can change the refresh interval in index.php

Page 1 = index.php -



      Bitcoin Price
     
     
     
     

     
     
     



Wait 10 Seconds..






Page 2 = gox.php -

header('Cache-Control: no-cache, no-store, must-revalidate'); // HTTP 1.1.
header('Pragma: no-cache'); // HTTP 1.0.
header('Expires: 0'); // Proxies.

$data = file_get_contents("https://data.mtgox.com/api/2/BTCUSD/money/ticker_fast");
$data = json_decode($data, true);
$spot_last = $data['data']['last']['value'];
print_r($spot_last);
?>

Try That.
legendary
Activity: 1135
Merit: 1166
I can write up either a PHP or JavaScript version, if you like.  Of course it depends on your hosting provider, whether or not that will be useful to you.  If you promise me a small BTC donation and let me know what of those languages you want, I'll do it today in the evening (according to CEST time). Wink
member
Activity: 84
Merit: 10
www.coincloud.tk :)
Okay, It seems it will probably be better in the long-run to switch host now before I want to add anything else I can't..
I'll scour around for pre-made php version's or something but I'll probably get stuck again Tongue Thank you for now!
sr. member
Activity: 287
Merit: 250
Sad Ah, nothing I want to do is straight forward, heh..
I don't suppose anyone knows of any website offering a c+p .. premade ticker thing? Tongue
Else I will find a different host who are dumbass friendly but offer php/java Tongue
Ty for the replies also! Smiley

I don't think it will be easy as drag/drop unfortunately.

Do note that I was talking about Javascript which is completely different from java, the first one does not need to be supported by the website hoster (only allowed because of security if you have something like a drag and drop websitemaker) and the second thing is something they need to install, support and offer to you.
member
Activity: 84
Merit: 10
www.coincloud.tk :)
Sad Ah, nothing I want to do is straight forward, heh..
I don't suppose anyone knows of any website offering a c+p .. premade ticker thing? Tongue
Else I will find a different host who are dumbass friendly but offer php/java Tongue
Ty for the replies also! Smiley
sr. member
Activity: 287
Merit: 250
You don't need a server side language like PHP and no drag and drop site maker I know of supports custom server side stuff. You also can't do it in HTML as it is no programming language but a markup language.

I would check if they support javascript snippets (or script tags). If Javascript (JS) is not allowed the only other option I can think of is to load an external image with the price embedded in the picture. This means that you need someone that will parse the price every minute or something and embed it in a picture.
sr. member
Activity: 467
Merit: 250
You'll need PHP to parse out the price from the json ticker from the bitcoin exchanges.
member
Activity: 84
Merit: 10
www.coincloud.tk :)
Hello BCT.org community! As always, apologies if this is in the wrong section! Tongue - I'm making a little website and wish to display the current average price of a BTC either from a blockchain/btce/mt gox ticker but am useless as putting together any code I find.. I'm hoping to display either in text or a simple image the price of bitcoin, which will auto-update when the source does..


I'm currently using simple drag and drop site makers but they allow custom HTML and hope I can copy and paste something and edit it how I like.
(not looking to get slated for this..)

I'd be very grateful of anyone who has a good knowledge of html and can write up a basic code I can copy and paste!

:p prize for the most to the point answer! Smiley


The output should resemble:

[1 BTC = $101 / £65 / €76]
 OR
[1 BTC = $101]
[1 BTC = £65]
1 BTC =  €76]

Thank you!

Jump to: