Phiên bản đầy đủ: jsB@nk » » Liên kết tạo chữ lớn dần 2
URL: https://www.javascriptbank.com/flashlike-rollover-animation-for-all-your-links.html
Hiệu ứng tạo ra chữ "O" xuất hiện với kích thước vừa lớn dần vừa tan dần ngay chỗ liên kết khi ta rê chuột đến.
Phiên bản đầy đủ: jsB@nk » » Liên kết tạo chữ lớn dần 2
URL: https://www.javascriptbank.com/flashlike-rollover-animation-for-all-your-links.html
<SCRIPT>// CREDITS:// Flashlike rollover-animation for all your links// by Urs Dudli and Peter Gehrig // Copyright (c) 2000 Peter Gehrig and Urs Dudli. All rights reserved.// the number of ringsvar ringnumber=4// do not edit the code belowvar x,yvar timervar i_fontsize=new Arrayvar step=new Arrayringnumber=ringnumber-1var maxfontsize=600var startfontsize=1for (i=0;i<=ringnumber;i++) {i_fontsize[i]=startfontsizestep[i]=ringnumber*i*10startfontsize=(maxfontsize/ringnumber)*(i+1)}function cursorposition(e){x=event.clientX+document.body.scrollLefty=event.clientY+document.body.scrollTop}function showrings() {if (document.all) {for (i=0;i<=ringnumber;i++) {if (i_fontsize[i]>=maxfontsize) {i_fontsize[i]=1;step[i]=1}var thisring=eval("document.all.ring"+i+".style")thisring.visibility="visible"thisring.fontSize=i_fontsize[i]thisring.color="rgb("+Math.floor(i_fontsize[i]/2.0)+","+Math.floor(i_fontsize[i]/2.0)+",255)" thisring.posLeft=x-(Math.floor(i_fontsize[i]/3))thisring.posTop=y-(Math.floor(i_fontsize[i]/1.4))step[i]+=2i_fontsize[i]+=step[i]}timer=setTimeout("showrings()",50)}}function hiderings(e){if (document.all) {clearTimeout(timer)startfontsize=0for (i=0;i<=ringnumber;i++) {thisring=eval("document.all.ring"+i+".style")thisring.visibility="hidden"i_fontsize[i]=startfontsizestep[i]=ringnumber*i*10startfontsize=Math.floor((maxfontsize/ringnumber))*(i+1)}}}if (document.all) {document.onmousemove=cursorposition;}if (document.all) {for (i=0;i<=ringnumber;i++) {document.write("<DIV id='ring"+i+"' style='position:absolute;font-family:Verdana;'>o</DIV>")}document.write("<DIV style='position:relative;'>")}</SCRIPT><!-- This script downloaded from www.JavaScriptBank.com Come to view and download over 2000+ free javascript at www.JavaScriptBank.com-->
Just move your mouse over<a onmouseout="hiderings()" onmouseover="showrings()" href="http://javascriptbank.com">this textlink</a><!-- This script downloaded from www.JavaScriptBank.com Come to view and download over 2000+ free javascript at www.JavaScriptBank.com-->