Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author vaakash

    (@vaakash)

    Please note shortcoder can execute any HTML, JS placed in it.
    Your query is not related to shortcoder.

    Anyways, I just wrote a small snippet to get the data, assuming jQuery is used in your page.

    Shortcode content:

    <span class="btc_eur"></span>
    <script>
    (function($){
    	var cmc_ajax = $.getJSON('https://api.coinmarketcap.com/v1/ticker/bitcoin/?convert=EUR');
        cmc_ajax.done(function(data){
        	$('.btc_eur').text(data[0]['price_eur']);
        });
    })(jQuery);
    </script>
    Thread Starter acrypto

    (@acrypto)

    Thank you,

    This works like a charm.

    Cheers

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Pull data from coinmarketcap?’ is closed to new replies.