소스는 적당한 곳에 넣어 주시고 <body onload="doWave(0)"> 이걸 바디에 넣어주세요.
<script language="JavaScript">
/*
script edited by David Gardner (toolmandav@geocities.com)
Permission granted to Dynamicdrive.com to feature the script
For more DHTML scripts, visit Dynamicdrive.com
*/
//put your text here
var theText = "http://oxtag.wo.to";
function nextSize(i,incMethod,textLength)
{
if (incMethod == 1) return (72*Math.abs( Math.sin(i/(textLength/3.14))) );
if (incMethod == 2) return (255*Math.abs( Math.cos(i/(textLength/3.14))));
}
function sizeCycle(text,method,dis)
{
output = "";
for (i = 0; i < text.length; i++)
{
size = parseInt(nextSize(i +dis,method,text.length));
output += "<font style='font-size: "+ size +"pt'>" +text.substring(i,i+1)+ "</font>";
}
theDiv.innerHTML = output;
}
function doWave(n)
{
sizeCycle(theText,1,n);
if (n > theText.length) {n=0}
setTimeout("doWave(" + (n+1) + ")", 50);
}
</script>
</p>
<div id="theDiv" align="center"> </div>
<script language="JavaScript">
/*
script edited by David Gardner (toolmandav@geocities.com)
Permission granted to Dynamicdrive.com to feature the script
For more DHTML scripts, visit Dynamicdrive.com
*/
//put your text here
var theText = "http://oxtag.wo.to";
function nextSize(i,incMethod,textLength)
{
if (incMethod == 1) return (72*Math.abs( Math.sin(i/(textLength/3.14))) );
if (incMethod == 2) return (255*Math.abs( Math.cos(i/(textLength/3.14))));
}
function sizeCycle(text,method,dis)
{
output = "";
for (i = 0; i < text.length; i++)
{
size = parseInt(nextSize(i +dis,method,text.length));
output += "<font style='font-size: "+ size +"pt'>" +text.substring(i,i+1)+ "</font>";
}
theDiv.innerHTML = output;
}
function doWave(n)
{
sizeCycle(theText,1,n);
if (n > theText.length) {n=0}
setTimeout("doWave(" + (n+1) + ")", 50);
}
</script>
</p>
<div id="theDiv" align="center"> </div>
'인터넷관련' 카테고리의 다른 글
글씨가 위에서 아래로 떨어지면서 고정되는 스크립트 (0) | 2008.01.24 |
---|---|
글씨가 오른쪽 위에서 튀어나와 고정 되는 소스 (0) | 2008.01.24 |
text 타이핑 효과 - 글자 타이핑 (0) | 2008.01.24 |
글이 스크롤 되면서 안개처럼 사라집니다/칼라변화/링크지원 (0) | 2008.01.24 |
타이틀에 날짜 표시하기 - Date (0) | 2008.01.24 |
링크된 곳에 마우스 오버시 스크롤 텍스트 (0) | 2008.01.24 |
커서를 쫓아다니는 글씨 효과 (0) | 2008.01.24 |
마우스 커서를 맴도는 매직효과 (0) | 2008.01.24 |