Title: Bitcoin & Altcoins Live Price Image generator Post by: edgycorner on May 02, 2018, 03:15:06 PM I have created a simple project, which will generates image with live price of any crypto-currency.It can embedded in posts as an image.
By using this simple URL: Code: http://liveimage-liveimage.193b.starter-ca-central-1.openshiftapps.com/image.php?coin=NAME With amount: Code: http://liveimage-liveimage.193b.starter-ca-central-1.openshiftapps.com/image.php?coin=NAME&amount=AMOUNT With currency and amount: Code: http://liveimage-liveimage.193b.starter-ca-central-1.openshiftapps.com/image.php?coin=NAME&amount=AMOUNT¤cy=CURRENCY Currency:usd/aud/inr etcetra Replace "NAME" with the coin name( ex:bitcoin,litecoin,ripple,etheruem,bitcoincash,eos,etcetra) and "AMOUNT" with a number. Examples: Code: [img]http://liveimage-liveimage.193b.starter-ca-central-1.openshiftapps.com/image.php?coin=bitcoin[/img] Similarly, 3250 IOST Tokens: http://liveimage-liveimage.193b.starter-ca-central-1.openshiftapps.com/image.php?coin=iostoken&amount=3250 1000 Tron: http://liveimage-liveimage.193b.starter-ca-central-1.openshiftapps.com/image.php?coin=tron&amount=1000 1 Bitcoin in INR: http://liveimage-liveimage.193b.starter-ca-central-1.openshiftapps.com/image.php?coin=bitcoin¤cy=inr&amount=1 Domain Name? Not yet decided.If you have anything in mind, then feel free to reply here :D Let me know, what you think about it. Update:The caching issue has been fixed :D The images will be updated with live price after every reload. You can see it working here: https://bitcointalk.org/index.php?topic=3485867 https://github.com/edgycorner/Coin-Price-Image-generator/ Title: Re: Bitcoin & Altcoins Live Price Image generator Post by: roslinpl on May 04, 2018, 10:06:41 PM Hey,
this is actually very nice! I see the image width is set to fixed - I suggest to calculate the image width after your script know the price. Something like: Image width = number of digits * 10px + 50px 1 digit is ~10px wide. 'USD' + some margins is ~50px. Or you could limit the decimal. I will keep my eye on your project :) I wish you the best of luck! Title: Re: Bitcoin & Altcoins Live Price Image generator Post by: edgycorner on May 05, 2018, 09:55:27 AM Hey, this is actually very nice! I see the image width is set to fixed - I suggest to calculate the image width after your script know the price. Something like: Image width = number of digits * 10px + 50px 1 digit is ~10px wide. 'USD' + some margins is ~50px. Or you could limit the decimal. I will keep my eye on your project :) I wish you the best of luck! Thank you so much for being so generous. Yes, I will work upon your suggestion.I will limit the decimals plus will change the width accordingly.Need to fix few other things too. Thanks again :D Title: Re: Bitcoin & Altcoins Live Price Image generator Post by: vv181 on May 05, 2018, 11:01:31 AM Domain Name? cryptocapturecryptotracker Any information about the sources you gathered prices data? adding an option to show the converted result in Bitcoin would be good. Title: Re: Bitcoin & Altcoins Live Price Image generator Post by: reflector on May 05, 2018, 01:00:37 PM I have created a simple project, which will generates image with live price of any crypto-currency.It can embedded in posts as an image. By using this simple URL: Code: http://35.226.164.123/image.php?coin=NAME&amount=AMOUNT Replace "NAME" with the coin name( ex:bitcoin,litecoin,ripple,etheruem,bitcoincash,eos,etcetra) and "AMOUNT" with a number. Examples: Code: [img]http://35.226.164.123/image.php?coin=bitcoin&amount=3[/img] Similarly, 3250 IOST Tokens: http://35.226.164.123/image.php?coin=iostoken&amount=3250 1000 Tron: http://35.226.164.123/image.php?coin=tron&amount=1000 1 Bitcoincash: http://35.226.164.123/image.php?coin=bitcoincash&amount=1 Domain Name? Not yet decided.If you have anything in mind, then feel free to reply here :D Let me know, what you think about it. Update:The caching issue has been fixed :D The images will be updated with live price after every reload. You can see it working here: https://bitcointalk.org/index.php?topic=3485867 Really good work mate. I would like to find the more information like adding name details to show on the page and if you design the webpage with any good template you can gather for the more information designers over here. Check vod signature, she really made good work to find the various details about this forum one page. Since I like this work, I have merited you as well mate. Title: Re: Bitcoin & Altcoins Live Price Image generator Post by: edgycorner on May 06, 2018, 08:33:29 PM Domain Name? cryptocapturecryptotracker Any information about the sources you gathered prices data? adding an option to show the converted result in Bitcoin would be good. Really good work mate. I would like to find the more information like adding name details to show on the page and if you design the webpage with any good template you can gather for the more information designers over here. Check vod signature, she really made good work to find the various details about this forum one page. Since I like this work, I have merited you as well mate. I am busy with my college exams ATM :/ Will update everything once my exams are over .-. Title: Re: Bitcoin & Altcoins Live Price Image generator Post by: edgycorner on May 07, 2018, 01:52:05 PM Updated a few things:
1.) Changed background color & text color of the image. 2.) Only values till 4th decimal places will be printed. 3.) The width of the image is now dynamic, depending upon the length of the string. Things to do: 1.) Build the homepage and a link generator, with options like changing the font,color,currency,decimal place, etcetra 2.) Add a short domain name. 3.) Will try to reduce the time taken to generate images. 4.) Make it open source once everything is built & final. Title: Re: Bitcoin & Altcoins Live Price Image generator Post by: Joel_Jantsen on May 07, 2018, 06:56:29 PM This is really cool! I just tried my first image generation at http://35.226.164.123/image.php?coin=bitcoin&amount=123.So if you don't mind revealing your secret stash,how did you make it ? Does the image transformations happen on the fly or you fetch them from a server?
Either way,I'm happy to see such projects in this board. Title: Re: Bitcoin & Altcoins Live Price Image generator Post by: TryNinja on May 07, 2018, 07:00:12 PM This is really cool! I just tried my first image generation at http://35.226.164.123/image.php?coin=bitcoin&amount=123.So if you don't mind revealing your secret stash,how did you make it ? Does the image transformations happen on the fly or you fetch them from a server? It's probably pretty simple.Either way,I'm happy to see such projects in this board. Just fetch the Bitcoin price from an API (i.e CoinMarketCap) and calculate how much the amount is worth, then create an image with this method1] or similar. [1] http://php.net/manual/en/function.imagettftext.php Title: Re: Bitcoin & Altcoins Live Price Image generator Post by: Joel_Jantsen on May 07, 2018, 07:18:26 PM This is really cool! I just tried my first image generation at http://35.226.164.123/image.php?coin=bitcoin&amount=123.So if you don't mind revealing your secret stash,how did you make it ? Does the image transformations happen on the fly or you fetch them from a server? It's probably pretty simple.Either way,I'm happy to see such projects in this board. Just fetch the Bitcoin price from an API (i.e CoinMarketCap) and calculate how much the amount is worth, then create an image with this method1] or similar. [1] http://php.net/manual/en/function.imagettftext.php Title: Re: Bitcoin & Altcoins Live Price Image generator Post by: TryNinja on May 07, 2018, 08:09:04 PM Ahh..I see! Never been a fan of PHP but this does sound extremely simple.So the 3rd party package is where all the magic happens. Great! Also I don't see the data being fetched from the server which actually confused me. Usually, my console or my terminal records all the API calls but when I opened the URL with the given params,I didn't see any network calls happening so I was a doubtful if it's happening on the fly. Thanks for the clarification. Because it's made with PHP. The API calls are happening on the server-side and not on the user's browser.The user only sees the already rendered image. Title: Re: Bitcoin & Altcoins Live Price Image generator Post by: vv181 on May 08, 2018, 11:23:39 AM 1.) Changed background color & text color of the image. I'd like the new updates, now the text seems pretty clear.4.) Make it open source once everything is built & final. Why you didn't make it as an open source project in the first place. I believe making it open source would do easily the job. Title: Re: Bitcoin & Altcoins Live Price Image generator Post by: edgycorner on May 08, 2018, 11:48:10 AM This is really cool! I just tried my first image generation at http://35.226.164.123/image.php?coin=bitcoin&amount=123.So if you don't mind revealing your secret stash,how did you make it ? Does the image transformations happen on the fly or you fetch them from a server? It's probably pretty simple.Either way,I'm happy to see such projects in this board. Just fetch the Bitcoin price from an API (i.e CoinMarketCap) and calculate how much the amount is worth, then create an image with this method1] or similar. [1] http://php.net/manual/en/function.imagettftext.php I'd like the new updates, now the text seems pretty clear. Thanks :>Why you didn't make it as an open source project in the first place. I believe making it open source would do easily the job. The source code is very messy ATM.Even though it has just 100 lines, still it's hard to understand. I will create a rep at github after tidying the code, as soon as I can. Thanks for following the project guys, appreciate it! Title: Re: Bitcoin & Altcoins Live Price Image generator Post by: hugeblack on May 08, 2018, 04:26:52 PM Good work I've noticed the image's insensitivity to the case of characters:
1. You can add currency shortcuts like BTC, ETH, and LTC. 2. The image appearance time is relatively long, maybe because of my browser. 3. Edit the problem of negative values [http://35.226.164.123/image.php?coin=Bitcoin&amount=-1] 4. add colors if the price goes up or down. I do not know, but it may be possible to update values using the script rather than manually updating Title: Re: Bitcoin & Altcoins Live Price Image generator Post by: edgycorner on May 10, 2018, 10:18:28 AM Looks like I have exhausted my free 300$ google credits .-.
Will git the project and will add the domain, once I get time(4~5 days). Title: Re: Bitcoin & Altcoins Live Price Image generator Post by: eternalgloom on May 10, 2018, 10:53:25 AM This is something really useful and I've been looking for something like this to use in my Steemit posts.
Looking forward to you setting up a decent website to offer this as a service! Too bad I can't see the images, wish someone would have posted a screenshot :P Title: Re: Bitcoin & Altcoins Live Price Image generator Post by: edgycorner on May 28, 2018, 05:03:43 PM Update
I have shifted the project to openshift, and the updated the post with the new URL http://liveimage-liveimage.193b.starter-ca-central-1.openshiftapps.com/image.php?coin=NAME It is too long to be remembered ATM, will update with a domain soon. Added an option of currency too, /image.php?coin=COIN¤cy=CURRENCY Currency can be usd,aud,inr,cad,gbp,krw,jpy,rub, etcetra. PM me if you can't generate image using your currency. You can even use btc(for bitcoin); eth(ether) as currency. You can view the code here https://github.com/edgycorner/Coin-Price-Image-generator/ The price is now fetched from coingecko. Please let me know, if you find any problem.Thanks! Title: Re: Bitcoin & Altcoins Live Price Image generator Post by: cpoer2011 on June 04, 2018, 10:36:05 PM That's a great bitcoin and Altcoins live image generator you have made. I like it. You have done a great job by making it. Thanks for your effort. You have nailed it. :)
|