<div class="codetitle"> <span><a style="CURSOR: pointer" data="21471" class="copybut" id="copybut21471" onclick="doCopy('code21471')"><u>코드 복사</u></a></span> 코드는 다음과 같습니다.</div> <div class="codebody" id="code21471"> <br><script type="text/javascript"> <BR> var time = 300; <BR>var h = 0; <BR>function addCount() <BR>{ <BR>if(time>0) <BR>{ <BR>time--; h = h 5; } <BR>document.getElementById("ads").style.display = ""; <BR>document.getElementById("ads").style.height = h "px" <BR>setTimeout("addCount() ",30 ); <BR>} <BR>window.onload = function showAds() <BR>{ <BR>addCount(); <BR>setTimeout("noneAds()",7000); //숙박 시간 직접 조정<BR>} <BR>var T = 300; <BR>var N = 300; //Height<BR>function noneAds() <BR>{ <BR>if(T>0) <BR> { <BR>T --; N = N-5 <BR>} <BR>else <BR>{ <BR>return <BR>} <BR>(N<0) <BR> { <BR>document .getElementById("ads").style.display = "none"; <BR>return; <BR>} <BR>document.getElementById("ads").style.height = N "px" ; <BR>setTimeout ("noneAds()",30) <BR></script> <br><br> <br><br><br><br><br> <br><br><br> 코드는 다음과 같습니다.<br><br> <br><div style="MARGIN: 0px auto; WIDTH: 900px; BACKGROUND: #369; HEIGHT: 300px; COLOR: #fff" id="ads">스크립트 Home_www.jb51.net</div> </div> <br>