這是我的Web應用程序的一個骯髒的JSFiddle版本,但是,我不明白如何從Unix TimeStamp中適當調整日期,我要顯示的只是月份,日期和年份。正確顯示Instagram日期
任何幫助將不勝感激!
這裏是代碼:
$(function() {
$.ajax({
type: "GET",
dataType: "jsonp",
cache: false,
url: "https://api.instagram.com/v1/tags/crookedspaces/media/recent/?access_token=16741082.1b07669.121a338d0cbe4ff6a5e04543158a4f82",
success: function(data) {
console.log(data);
//OKAY, now lets get to the pretty stuff, INSTAGRAM PEEKTARS.
for (var i = 0; i < 5; i++) {
$(".instagram").append("\
<div class='instagram-feed'>\
<img class='instagram-image' src='" + data.data[i].images.standard_resolution.url +"' width='325px'/>\
<div class='igHover2'>\
posted by: "+data.data[i].user.username+"<br />\
posted on: "+Date(data.data[i].created_time).toString()+"<br />\
</div />\
</div>\
");
}
}
});
});
這似乎是工作,太感謝你了! – tbremer
@tbremer不客氣! –