웹마스터 팁
page_full_width" class="col-xs-12" |cond="$__Context->page_full_width">
앗!! 내별!! 내별날라가네
2006.10.14 12:38
아래 소스를 <head>와 </head>사이에 넣으세요.
<style type="text/css">
#s0, #s1, #s2, #s3, #s4, #s5, #s6, #s7, #s8, #s9
{
position:absolute; left:-10; top:-10; height:1; width:1;
}
</style>
<script language="JavaScript1.2">
<!--
var ns=(document.layers);
var ie=(document.all);
var w3=(document.getElementById && self.innerWidth && (window.pageXOffset>-1));
//my way of making sure the browser will have what I need
var allDivs = new Array(10);
var documentWidth,documentHeight;
function initAll(){
if(!ns && !ie && !w3) return;
for(dNum=0; dNum<10; ++dNum){
if(ie) allDivs[dNum]=eval('document.all.s'+dNum+'.style');
else if(ns) allDivs[dNum]=eval('document.layers["s'+dNum+'"]');
else if(w3) allDivs[dNum]=eval('document.getElementById("s'+dNum+'").style');
moveTo(dNum,0,0);
}
}
function moveTo(i,tempx,tempy){
if (ie){
documentWidth =document.body.offsetWidth+document.body.scrollLeft-20;
randomy=Math.floor(Math.random()*document.body.offsetHeight)+document.body.scrollTop-20;
}
else if (ns){
documentWidth=window.innerWidth+window.pageXOffset-20;
randomy=Math.floor(Math.random()*window.innerHeight)+window.pageYOffset-20;
}
else if (w3){
documentWidth=self.innerWidth+window.pageXOffset-20;
randomy=Math.floor(Math.random()*self.innerHeight)+window.pageYOffset-20;
}
if(tempx>-50){
tempx-=45;
allDivs[i].left=tempx;
allDivs[i].top =tempy;
setTimeout("moveTo("+i+","+tempx+","+tempy+")",40)
}
else
setTimeout("moveTo("+i+",documentWidth-10,randomy)",2000/i+40);
}
window.onload=initAll
//End-->
</script>
아래 소스를 <BODY>와 </body>사이에 넣으세요.
그림을 넣고 싶으실 때는 <div id="s0"><img src="그림 주소"></div>와 같이 태그를 써주세요.
<div id="s0" style="color:blue">☆</div>
<div id="s1" style="color:blue">★</div>
<div id="s2" style="color:blue">☆</div>
<div id="s3" style="color:blue">★</div>
<div id="s4" style="color:blue">☆</div>
<div id="s5" style="color:blue">★</div>
<div id="s6" style="color:blue">☆</div>
<div id="s7" style="color:blue">★</div>
<div id="s8" style="color:blue">☆</div>
<div id="s9" style="color:blue">★</div>
옆으로 날라간다;;;;;;
<style type="text/css">
#s0, #s1, #s2, #s3, #s4, #s5, #s6, #s7, #s8, #s9
{
position:absolute; left:-10; top:-10; height:1; width:1;
}
</style>
<script language="JavaScript1.2">
<!--
var ns=(document.layers);
var ie=(document.all);
var w3=(document.getElementById && self.innerWidth && (window.pageXOffset>-1));
//my way of making sure the browser will have what I need
var allDivs = new Array(10);
var documentWidth,documentHeight;
function initAll(){
if(!ns && !ie && !w3) return;
for(dNum=0; dNum<10; ++dNum){
if(ie) allDivs[dNum]=eval('document.all.s'+dNum+'.style');
else if(ns) allDivs[dNum]=eval('document.layers["s'+dNum+'"]');
else if(w3) allDivs[dNum]=eval('document.getElementById("s'+dNum+'").style');
moveTo(dNum,0,0);
}
}
function moveTo(i,tempx,tempy){
if (ie){
documentWidth =document.body.offsetWidth+document.body.scrollLeft-20;
randomy=Math.floor(Math.random()*document.body.offsetHeight)+document.body.scrollTop-20;
}
else if (ns){
documentWidth=window.innerWidth+window.pageXOffset-20;
randomy=Math.floor(Math.random()*window.innerHeight)+window.pageYOffset-20;
}
else if (w3){
documentWidth=self.innerWidth+window.pageXOffset-20;
randomy=Math.floor(Math.random()*self.innerHeight)+window.pageYOffset-20;
}
if(tempx>-50){
tempx-=45;
allDivs[i].left=tempx;
allDivs[i].top =tempy;
setTimeout("moveTo("+i+","+tempx+","+tempy+")",40)
}
else
setTimeout("moveTo("+i+",documentWidth-10,randomy)",2000/i+40);
}
window.onload=initAll
//End-->
</script>
아래 소스를 <BODY>와 </body>사이에 넣으세요.
그림을 넣고 싶으실 때는 <div id="s0"><img src="그림 주소"></div>와 같이 태그를 써주세요.
<div id="s0" style="color:blue">☆</div>
<div id="s1" style="color:blue">★</div>
<div id="s2" style="color:blue">☆</div>
<div id="s3" style="color:blue">★</div>
<div id="s4" style="color:blue">☆</div>
<div id="s5" style="color:blue">★</div>
<div id="s6" style="color:blue">☆</div>
<div id="s7" style="color:blue">★</div>
<div id="s8" style="color:blue">☆</div>
<div id="s9" style="color:blue">★</div>
옆으로 날라간다;;;;;;
댓글 3
-
파우
2006.12.27 02:22
제목 참 재밌고 귀엽게 쓰시네요^ㅁ^제목이 눈에띄어 클릭했답니다~ -
Goldcocktail
2007.06.28 23:38
-
유성매직
2007.11.20 21:50
멋져요...
그런데 혹시 앞으로 날아오는 건 없을까요?
제목 | 글쓴이 | 날짜 |
---|---|---|
[동주아빠] PHP 게시판 만들기 기초 (6) require,include [5] | 손병목 | 2002.12.25 |
[동주아빠] PHP 게시판 만들기 기초 (5) 제어문(下) [10] | 손병목 | 2002.12.25 |
[동주아빠] PHP 게시판 만들기 기초 (5) 제어문(上) [9] | 손병목 | 2002.12.25 |
[동주아빠] PHP 게시판 만들기 기초 (4) 연산자 [10] | 손병목 | 2002.12.25 |
[동주아빠] PHP 게시판 만들기 기초 (3) 변수와 배열 [6] | 손병목 | 2002.12.25 |
[동주아빠] PHP 게시판 만들기 기초 (2) [12] | 손병목 | 2002.12.25 |
[동주아빠] PHP 게시판 만들기 기초 (1) 준비 [8] | 손병목 | 2002.12.25 |
if 문으로 xxx.php?db=src 이런식으로 해보자..(제1탄 기초를 확!) [14] | inging-zb41 | 2002.12.12 |
왕초보용 개판 오분전 황당 쿠키(4) [2] | 미친개 | 2002.12.09 |
왕초보용 개판 오분전 황당 쿠키(3) [2] | 미친개 | 2002.12.09 |
왕초보용 개판 오분전 황당 쿠키(2) [6] | 미친개 | 2002.12.09 |
왕초보용 개판 오분전 황당 쿠키(1) [4] | 미친개 | 2002.12.09 |
PHP 각종 오류 정리 [15] | TheMics | 2002.12.04 |
MYSQL CLASS | 위선OSE | 2002.12.03 |
파일처리 - fseek [3] | 위선OSE | 2002.12.03 |
제로카운터 접속자 수 조정, 최고 간편한 팁(5초 소요, DB보존) [4] | 고광욱 | 2002.12.01 |
카드 결재시 사용되는 자바스크립트와 html [3] | 한꼬마 | 2002.11.28 |
카드 결재 개요 (텔렉) [2] | 한꼬마 | 2002.11.26 |
휴대폰 결재 활용 (최종) | 한꼬마 | 2002.11.26 |
휴대폰 결재 설치 및 테스터 [3] | 한꼬마 | 2002.11.24 |