Jika sobat tidak mau ambil pusing letakan saja script dan kodenya semua pada bagian Add a Gadget pilih yg HTML/Javascript :D Nanti pas mouse dihadapkan pada banner, akan berganti dengan banner lain begitu seterusnya sebanyak banner yg dimiliki ;) Kode dan scriptnya [..]
function rotate_banner(locator)
{
var pick=Math.round(1+((Math.random()*7)-0.5));
var banner=new Array(8)
banner[0]="<a href=\"HTTP://YOUR-LINK.COM/\"><img style=\" width: 100%;\" src=\"HTTP://YOUR-LINK-IMAGE.JPG\" alt=\"BLAH-BLAH\"></a>";
banner[1]="<a href=\"HTTP://YOUR-LINK.COM/\"><img style=\" width: 100%;\" src=\"HTTP://YOUR-LINK-IMAGE.JPG\" title=\"BLAH-BLEH\" alt=\"BLAH-BLAH\"></a>";
banner[2]="<a href=\"HTTP://YOUR-LINK.COM\" ><IMG SRC=\"HTTP://YOUR-LINK-IMAGE.JPG\" WIDTH=\"100%\" HEIGHT=\"60\" ALT=\"BLAH-BLAH\" BORDER=\"0\" ></A>";
banner[3]="<a href=\"HTTP://YOUR-LINK.COM\" ><IMG SRC=\"HTTP://YOUR-LINK-IMAGE.JPG\" WIDTH=\"100%\" HEIGHT=\"60\" ALT=\"BLAH-BLAH\" BORDER=\"0\" ></A>";
banner[4]="<a href=\"HTTP://YOUR-LINK.COM/\" ><img border=\"0\" src=\"HTTP://YOUR-LINK-IMAGE.JPG\" width=\"100%\" height=\"60\" alt=\"BLAH-BLAH\" /></a>";
banner[5]="<a href=\"HTTP://YOUR-LINK.COM/\" ><img border=\"0\" src=\"HTTP://YOUR-LINK-IMAGE.JPG\" width=\"100%\" height=\"60\" alt=\"BLAH-BLAH\" /></a>";
banner[6]="<a href=\"HTTP://YOUR-LINK.COM/\" ><img src=\"HTTP://YOUR-LINK-IMAGE.JPG\" border=0 width=\"100%\" height=\"60\"></a>";
banner[7]="<a href=\"HTTP://YOUR-LINK.COM\"><img src=\"HTTP://YOUR-LINK-IMAGE.JPG\" border=0 width=\"100%\" height=\"60\"></a>";
document.getElementById(locator).innerHTML = banner[pick];
}
</SCRIPT>
<span onmouseout="rotate_banner('b1')" id="b1">
<a href="HTTP://YOUR-LINK.COM/"><img src="HTTP://YOUR-LINK-IMAGE.JPG" title="" alt=""></a>
</span>
Happy blogging and good luck \m/
Loading... |
6 comments
DO NOT EVEN TRY ADD LINK [-X
You can use some HTML tags, such as
<b> - <i> - <a> - http://...jpg/gif/png/bmp - http://youtu.be/...