Hari nie aku nak share dalam ruangan TIPS BLOGGER satu lagi widget untuk korang semua. WIDGET TOP COMMENTATORS. Rasanya korang mesti penah tengok kat blog orang lain widget nie kan. So kat sini korang leh copy n paste script widget nie kat HTML /Javascipt. Contoh widget nie macam kat bawah:-
Tak susah pun nak setup widget nie. Mudah jer. Ikut langkah kat bawah nie:-
Terus masuk ke DESIGN klik PAGE ELEMENTS then klik ADD A GADGET
Pilih HTML/Javascript then masukkan kod kat bawah nie:
<script type="text/javascript">
function getYpipe(feed) {
document.write('<ul style="list-style-image: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhf48OUGFnpvNkKPz8HeTDmvG3xw9qxy0su-9OH_YC9Tzt0iGyocQ5H3AhnxpYRMEkUeEoYeGCUAMPUpwlHaJIzT0mlOIdUBmkJNSBe5K3O1iUg1Pb1XQAbj6TOJC_hRX-p-xBKC1xbHDY/s1600/circle-arrow-blue.png);margin-left: 20px;">');
var i;
for (i = 0; i < feed.count ; i++)
{
var href = "'" + feed.value.items[i].link + "'";
if(feed.value.items[i].link == "")
var item ="<li>" + feed.value.items[i].title + "</li>";
else
var item = "<li>" + "<a href="+ href + '" target="_blank">' + feed.value.items[i].title + "</a> </li>";
document.write(item);
}
document.write('</ul>');
}
</script>
<script src="http://pipes.yahoo.com/pipes/pipe.run?
YourBlogUrl=http://dezamancottage.blogspot.com
&ExcludedNick1=Hantu
&ExcludedNick2=anonymous
&ShowHowMany=10
&_callback=getYpipe
&_id=23022d7836bf2dd3c10a329feb9be26a
&_render=json"
type="text/javascript"></script>
<span style="font-size: 50%; float:right;">Get this <a href="http://dezamancottage.blogspot.com">widget</a></span>
function getYpipe(feed) {
document.write('<ul style="list-style-image: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhf48OUGFnpvNkKPz8HeTDmvG3xw9qxy0su-9OH_YC9Tzt0iGyocQ5H3AhnxpYRMEkUeEoYeGCUAMPUpwlHaJIzT0mlOIdUBmkJNSBe5K3O1iUg1Pb1XQAbj6TOJC_hRX-p-xBKC1xbHDY/s1600/circle-arrow-blue.png);margin-left: 20px;">');
var i;
for (i = 0; i < feed.count ; i++)
{
var href = "'" + feed.value.items[i].link + "'";
if(feed.value.items[i].link == "")
var item ="<li>" + feed.value.items[i].title + "</li>";
else
var item = "<li>" + "<a href="+ href + '" target="_blank">' + feed.value.items[i].title + "</a> </li>";
document.write(item);
}
document.write('</ul>');
}
</script>
<script src="http://pipes.yahoo.com/pipes/pipe.run?
YourBlogUrl=http://dezamancottage.blogspot.com
&ExcludedNick1=Hantu
&ExcludedNick2=anonymous
&ShowHowMany=10
&_callback=getYpipe
&_id=23022d7836bf2dd3c10a329feb9be26a
&_render=json"
type="text/javascript"></script>
<span style="font-size: 50%; float:right;">Get this <a href="http://dezamancottage.blogspot.com">widget</a></span>
Lepas semua dah selesai klik SAVE.
Korang nampakkan text warna MERAH kat script tu kan. Korang ganti ler ngan URL blog korang.
Kalau korang taknak Nick atau ID korang dikira sekali tengok kat text warna OREN. Korang leh ler excludedNick1 korang. Letak ler ID atau Nick korang kat situ so system tak kira ID korang tu.
Korang juga leh set jumlah COMMENTATORS. Nampak text warna BIRU tu kan ubah ler jumlah yang korang nak tak kira ler nak 10 ke 20 ke 100 ke 1000 ikut suka hati korang ler.
So dah selesai ler proses pasang widget TOP COMMENTATORS lepas tu leh ler view kat blog korang tengok ID mana yang aktif tinggalkan komen kat blog.
Selamat mencuba.