// onDomReady
$(function () {
        $("#stockquote p.quote").each(function(i) {
                var _this = this;
                
                $.getJSON("http://ws.blocksglobal.com/stocks/" + this.id + ".AX?callback=?", function(response) {
                        
                        _this.innerHTML = response.last_trade_price
                        $("p.date:eq(" + i + ")")[0].innerHTML = "ASX as at "+response.last_trade_time_new+"<br>"+response.last_trade_date;;

                });
        });
});
