Sabtu, 18 Februari 2012

reading list versi ( jadul )

·


This time I will discuss about the reading list ..
maybe you have not yet know about the blog content is what ..

There was a wide view, and I will give one example of such a wall display faceebook, interesting is not it?

diantra you may already know ..
for those who do not know the example is like this ..





Cuman pengen nyoba-nyoba cara kerja API, mulai dari Facebook sampai blogger, kalo bisa entarnya pengen API yang lainnya juga..
Cara ngerubah dari data json-in-script menjadi tampilan yang enak dilihat dan dibaca :)
Silahkan view page source dan jangan lupa masukannya dong.. :)














If you are interested, please copy the script below ..






<img src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh9o9FD6IY-plBkMg5in1dozQxH-MsgQ3802ScjrH6cIFDzUjVG4_E_nMd2A4brOlSnXDdbXFaLrrunDSLKBRQOYGBJNXlIFfSuZ2wFCwHNgqql5h7jvvhDjFQu60O1iVuzTtBS1e_bfLOl/s1600/gdata-blogger-icon.png" style="display:none;"/>
<p style="display:none;">Cuman pengen nyoba-nyoba cara kerja API, mulai dari Facebook sampai blogger, kalo bisa entarnya pengen API yang lainnya juga..
Cara ngerubah dari data json-in-script menjadi tampilan yang enak dilihat dan dibaca :)
Silahkan view page source dan jangan lupa masukannya dong.. :)</p>

<div id="sono-aje-gan" style="padding-bottom:0;"></div>
<div id="sini-aje-gan" style="padding-top:0;"></div>

<style type="text/css"><!--
h3.post-title{display:none}
.post-body{
font-family:Walter Turncoat,tahoma,verdana,arial,sans-serif;
font-size:11px; margin-top:10px;
/* width:500px; margin:auto; background:black;*/
}
.white80{
background-color:transparent;
/* background-image:url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj6Wy0Xtj2HC_BCgOHe0f6v_PNApbs1GLXEa8ZDKCw3oJdqhX-wBD944Jqj9APK8fByFYGevfjrTuK49Bgo0pLC9Ty3_iGMEHi-ZIxLfXcQIqRBbqLWfEjx9Ogh7nysF0PG0ey83Li6xjuN/s1600/white80.png); */
}
.bodybirds{
background-color:transparent;
background-image:url(http://www.blogblog.com/1kt/watermark/body_background_birds.png);
}
.post-body a, .post-body a:visited{
color:#3B5998;
text-decoration:none;
}
.post-body a:hover{
color:#983B59;
text-decoration:underline;
}
.box-komen-up{
background:transparent url(http://static.ak.fbcdn.net/rsrc.php/v1/y7/r/UvyvLtJTQzO.png) no-repeat scroll 16px 0;
height:5px;
}
.box-komen{
background:#EDEFF4;
border-bottom:1px solid #D2D9E7;
margin-bottom:1px;
padding:5px 5px 4px;
font-size:11px;
position:relative;
}
.gbr-kmn{
background:transparent url(http://static.ak.fbcdn.net/rsrc.php/v1/y3/r/YPFeM0EXezc.png) no-repeat scroll -170px -91px;
height:16px; width:16px;
display:inline-block;
vertical-align:middle;
margin-right:3px;
}
.gbr-jmpl-like{
background:transparent url(http://static.ak.fbcdn.net/rsrc.php/v1/yU/r/DpIr-7bdqXs.png) no-repeat scroll 0 -44px;
height:15px; width:15px;
display:inline-block;
vertical-align:bottom;
margin-right:5px;
}
.lampiran table, .lampiran table tr, .lampiran table tr td{
padding:0; margin:0; border:none; font-size:11px; color:#707070;
}
--></style>

<script type="text/javascript">
<!--
if(!document.getElementById('fb-root')){document.write('<div id="fb-root"></div>')}

var authFB = [
"05365000075418154395_100000381466661",
"100167812137968467021_100000381466661",
"07829522109484211685_100002416157212",
"117177112174604237317_100002416157212",
"104433761873179577172_100000578157367",
"00190986811067553859_100001244884194",
"02268648262107534152_100003236666657",
"16415858093209172071_100002241973501",
"05615472339916877323_100002096713555",
"10366306966235863673_100002525655427",
"06564201223558440734_100003056792239",
"11458909785403928523_264138420313053",
"13746124865939817082_100003012298172",
"01349696871870383713_100000593976869",
"11531225608432599428_1719623186",
"04431029684897311788_1819078396",
"15636626689584442172_1251567873",
"06843440787806727805_1736814315",
"11475658087883730950_1359064985",
"06690784352607471139_100001325691112",
"17340953387551006068_100003079312596",
"17129891955470295366_100001699028582",
"17203184695741164502_100001662227949",
"01380081905040422947_100000609451544",
"09357898127879347717_100000676761074",
"06212156973685556279_100002388243645",
"00034296296893360114_243299109072789",
"17280268400770809836_100001807501560",
"09560585883975898789_100001612110221",
"12567292286809438833_103096743066179",
"15655763734353316010_100000067603062",
"01732680164278661262_100001851580451",
"02612810299863107450_100002070831048",
"13772782807658815198_100000653280442",
"17080427603245230168_100001407686413",
"04703239991960991097_100001136956646",
"13812832174324850516_100001504105101",
"12231576064810169921_100001388998112",
"00801984436598271955_100001067515356",
"01758001585913087128_100001210969291",
"12411180628617256839_100001751060579",
"00398102502092541629_100001438381562",
"09400748415386546339_100000065798770",
"06328709432271990308_100000377920347",
"13485104513706664731_100002838410778",
"14007700979128764135_100000509468125",
"01417793773650140607_100001758972790",
"14689422556835902899_100000464709703",
"14689422556835902899_543767133",
"01881699521328065128_100001112924726",
"17349004503496819593_100002453341098",
"00767317096804100188_100000228108592",
"09984945183155106551_100001641258742",
"17951524591257421466_1736880422",
"05209243600241896746_100002375355823",
"03635600178746542265_100002916751559",
];

function bagiStimGan(uri){
var e = document.createElement('script'); e.async = 'true';
e.src = uri;
document.getElementById('fb-root').appendChild(e);
}

function tulisStrimGan(nih){
document.getElementById('sini-aje-gan').innerHTML = '<div id="post-box-luar" class="white80"></div>';

nih.feed.entry = nih.feed.entry.sort(function() {return 0.5 - Math.random()});
for(x in nih.feed.entry){
var namaAuthor = ''; var lingAuthor = ''; var emailAuthor = ''; var idBlogAuthor = ''; var idFbAuthor = ''; var gbFbAuthor = 'http://profile.ak.fbcdn.net/hprofile-ak-snc4/49554_100000653280442_422999958_n.jpg';
for(y in nih.feed.entry[x].author){
if(nih.feed.entry[x].author[y].name){namaAuthor = nih.feed.entry[x].author[y].name.$t}
if(nih.feed.entry[x].author[y].uri){lingAuthor = nih.feed.entry[x].author[y].uri.$t; idBlogAuthor = lingAuthor.split('/')[4]}
if(nih.feed.entry[x].author[y].email && nih.feed.entry[x].author[y].email.$t!='noreply@blogger.com'){emailAuthor = nih.feed.entry[x].author[y].email.$t}
}
if(idBlogAuthor!=''){for(y in authFB){if(authFB[y].split('_')[0]==idBlogAuthor){idFbAuthor=authFB[y].split('_')[1]}}}

var tulis = '';
tulis += '<div class="post-box bodybirds" style="padding:10px 1px; margin:0 0 10px 0; color:#333333; border-bottom:1px solid #E9E9E9;">';
if(idFbAuthor==''){tulis += '<img src="'+gbFbAuthor+'" style="float:left; max-width:50px;"/>'}else{tulis += '<img src="http://graph.facebook.com/'+idFbAuthor+'/picture" style="float:left; max-width:50px;"/>'}

tulis += '<div style="margin-left:60px; padding-right:4px;">';
tulis += '<div class="nama-aktor">';
if(lingAuthor==''){tulis += '<b>'+namaAuthor+'</b>'}else{tulis += '<a href="'+lingAuthor+'" target="_blank" style="font-weight:bold">'+namaAuthor+'</a>'}
if(emailAuthor!=''){tulis += ' <i>(<a href="mailto:'+emailAuthor+'">'+emailAuthor+'</a>)</i>'}
tulis += '</div>'; //nama-aktor

tulis += '<div class="lampiran" style="font-size:11px; color:#808080; margin:5px 0;">';
if(nih.feed.entry[x].media$thumbnail){
tulis += '<table cellpadding=0 cellspacing=0><tr><td style="vertical-align:top;"><img class="nostyle" src="'+nih.feed.entry[x].media$thumbnail.url+'" style="max-width:90px; margin:3px 8px 0 0;"/></td><td style="vertical-align:top;">';
var divTab = '</td></tr></table>';
}else{
tulis += '<div style="border-left:2px solid #CCCCCC; padding:0 0 0 10px;">';
var divTab = '</div>';
}

var judulFeed = ''; var lingFeed = '';
for(y in nih.feed.entry[x].link){if(nih.feed.entry[x].link[y].rel=='alternate'){
judulFeed=nih.feed.entry[x].link[y].title; lingFeed=nih.feed.entry[x].link[y].href;
tulis += '<div class="nama-lampiran"><a href="'+lingFeed+'" style="font-weight:bold">'+judulFeed+'</a></div>';
break;
}}
tulis += '<div class="description-lampiran">';
if(nih.feed.entry[x].summary){
tulis += nih.feed.entry[x].summary.$t.split('<')[0].replace(/\n/gi,'<div></div>');
}else if(nih.feed.entry[x].content){
tulis += nih.feed.entry[x].content.$t.split('<')[0].replace(/\n/gi,'<div></div>');
}
if(lingFeed!=''){tulis += '.. <a href="'+lingFeed+'" title="'+judulFeed+'" style="white-space:nowrap;"><img src="http://www.castleinthecountry.com/wp-content/gallery/buttons/read-more-button.png" /></a>'}
tulis += '</div>'; //description-lampiran
tulis += divTab;
tulis += '</div>'; //lampiran

tulis += '<div class="footer-lampiran" style="font-size:11px; color:#999999;">';
if(nih.feed.entry[x].published){
tulis += '<span class="jam-lampiran"><span style="color:#8E8E8E">Published:</span> '+translateTgl(nih.feed.entry[x].published.$t)+'</span> ';
}
if(nih.feed.entry[x].updated){
tulis += ' &#183; ';
tulis += '<span class="jam-lampiran"><span style="color:#8E8E8E">Updated:</span> '+translateTgl(nih.feed.entry[x].updated.$t)+'</span> ';
}
if(nih.feed.entry[x].category){
tulis += ' &#183; ';
tulis += '<span class="appname-lampiran"><span style="color:#8E8E8E">Category:</span> ';
for(y in nih.feed.entry[x].category){if(y!=0){tulis += ','} tulis += nih.feed.entry[x].category[y].term}
tulis += '</span>';
}
tulis += '</div>'; //footer-lampiran

if(nih.feed.entry[x].thr$total){
tulis += '<div class="box-komen-up"></div>';
tulis += '<div class="box-komen post-box-dalem">';
tulis += '<i class="gbr-kmn"></i>';
if(nih.feed.entry[x].thr$total.$t==0){tulis += '<span style="vertical-align:middle">Post a comments</span>'}else{tulis += '<span style="vertical-align:middle">'+nih.feed.entry[x].thr$total.$t+' comments</span>'}
if(lingFeed!=''){var ini=lingFeed.split('/').length-1; tulis += ' <span id="'+lingFeed.split('/')[ini].split('.')[0]+'" style="vertical-align:middle"></span>'; bagiStimGan('http://graph.facebook.com/'+lingFeed+'?callback=tulisLikes')}
tulis += '</div>';
}

tulis += '</div>';
tulis += '</div>'; //post-box
tulis += '<div style="clear:both;"></div>';
document.getElementById('post-box-luar').innerHTML += tulis;
}
}

function tulisLikes(what){
if(what.link && what.likes){
var ini=what.link.split('/').length-1;
var elem=what.link.split('/')[ini].split('.')[0];
if(document.getElementById(elem)){document.getElementById(elem).innerHTML='<span style="vertical-align:middle"> &#183; </span><i class="gbr-jmpl-like"></i><span style="vertical-align:middle">'+what.likes+' People like this.</span>'}
}else if(what.shares && what.id){
var ini=what.id.split('/').length-1;
var elem=what.id.split('/')[ini].split('.')[0];
if(document.getElementById(elem)){document.getElementById(elem).innerHTML='<span style="vertical-align:middle"> &#183; </span><i class="gbr-jmpl-like"></i><span style="vertical-align:middle">'+what.shares+' People shares this.</span>'}
}
}

function translateTgl(what){
//format 2011-11-12T10:45:30

var getwhat=what.split('T')[0].replace(/-/gi,' ')+' '+what.split('T')[1].split('.')[0];
var d=new Date(getwhat);
var today=new Date();
var delta=today-d;

var harihari=["Minggu","Senen","Selasa","Rabu","Kamis","Jum'at","Sabtu"];
var bulanbulan=["January","February","Maret","April","Mei","June","July","Agustus","September","Oktober","November","Desember"];
var menit=getwhat.substr(14,2);
var jam=getwhat.substr(11,2);
var hari=getwhat.substr(8,2);
var nh=d.getDay();
var namaHari=harihari[nh];
var bulan=getwhat.substr(5,2);
var namaBulan=bulanbulan[(bulan-1)];
var taun=getwhat.substr(0,4);

var minutes=1000*60;
var hours=minutes*60;
var days=hours*24;
var month=days*30;
var years=days*365;

var naon=delta/minutes;
var iraha=Math.round(naon);
var harita='Karak ge crot bieu';

if(iraha>0 && iraha<60){
harita='Nembe '+Math.round(naon)+' menit bieu';
}else if(iraha>=60 && iraha<(60*24)){
naon=delta/hours; harita=Math.round(naon)+' jam tadi';
}else if(iraha>=(60*24) && iraha<(60*24*30)){
naon=delta/days; harita=Math.round(naon)+' hari kemaren';
}else{
harita=namaHari+', '+hari+' '+namaBulan+' '+taun+' jam '+jam+':'+menit;
}
return harita;
}

function postScript2(){
document.getElementById('sini-aje-gan').innerHTML = '<center>Lodding <img src="http://i579.photobucket.com/albums/ss233/jjiiaayyuunn/Blog/Crazy%20rabbit/th_patpat-dance-crazy-rabbit-emoticon.gif" /> doLo coyy.. Xd</a></center>';
var starindek = Math.floor(Math.random()*40);
bagiStimGan('http://namapanjang.blogspot.com/feeds/posts/default?alt=json-in-script&start-index='+starindek+'&max-results=5&callback=tulisStrimGan');
}

function postScript(){
stelMusikAh('http://irland.heck.in/files/lolita-cleopatra-strana.mp3','yes','no','LOLITA - CLEOPATRA STRANAN');
}

postScript2();
//-->

</script>







you'll live your own blog link exchange ..
and if you want to change the number of his post,
you are now looking for a script code ..
ctrt + f (later you said) max-result

I hope you succeed ..


see yoou .. ^_^

Tidak ada komentar: