ƯÁ¤ ÆäÀÌÁö¿¡ Á¢¼ÓÇÒ¶§ ¸¶´Ù ƯÁ¤ À̹ÌÁö¸¦ ´Ù¸£°Ô º¸¿©ÁÖ°í ½ÍÀ»¶§ »ç¿ëÇÒ ¼ö ÀÖ´Ù. ¾Æ·¡ µ¥¸ð¸¦ º¸°í ¸®·Îµå¸¦
Çغ¸¸é À̹ÌÁö°¡ Á¢¼ÓÇÒ¶§ ¸¶´Ù º¯Çϴ°ÍÀ» ¾Ë¼öÀÖ´Ù. »ç¿ëÇÏ´Â ¹æ¹ýÀº ´ÙÀ½°ú °°´Ù. ¿¹Á¦¿¡ º¸¿©Áø ¼Ò½º¸¦ ¿øÇÏ´Â
À̸§À¸·Î ÀúÀåÇÏ°í À̹ÌÁö¸¦ ÁöÁ¤ÇÏ´Â °÷(var BgArray ¶ó´Â °÷¿¡¼ ÁöÁ¤ÇÒ¼öÀÖ´Ù)¿¡ ³»°¡ ¿øÇÏ´Â À̹ÌÁö¸¦
ÁöÁ¤ÇÏ¸é µÈ´Ù.
script example |
<html> <head>
<SCRIPT LANGUAGE="JavaScript">
var BgArray = new Array( "./img/d15_work1.gif",
"./img/d15_work2.gif", "./img/d15_work3.gif",
"./img/d15_work4.gif", "./img/d15_work5.gif",
"./img/d15_work6.gif", "./img/d15_work7.gif"
);
var gifimage="";
var picfolder="./";
today=new Date();
jran=today.getTime();
ia=9301;
ic=49297;
im=233280;
jran = (jran*ia+ic) % im;
gifimage = picfolder+BgArray[ ( Math.ceil((jran/(im*1.0))
*BgArray.length) ) - 1]; </script>
</head> <body>
ÆäÀÌÁö¸¦ ¸®·Îµå Çغ¸¼¼¿ä ±×¸²ÀÌ º¯ÇÕ´Ï´Ù. <p>
<script>
document.write("<img src='"+gifimage+"'>");
</script> </body>
</html> |
|
|
¼³¸í |
À̹ÌÁö´Â Å©±â°¡ ´Ù¸£¸é ±× ÀüüÀûÀÎ ÇüÅ°¡ ¾î±ß³ª¹Ç·Î ±¸Á¶°¡ ¾î±ß³¯¶§´Â
»çÀÌÁî°¡ °°Àº À̹ÌÁö¸¦ »ç¿ëÇϵµ·Ï ÇÑ´Ù. À̹ÌÁöÀÇ ¼ö´Â »ó°ü¾ø´Ù. head
ÅÂ±× »çÀÌ¿¡ ÀÖ´Â script ű׸¦ ÀÚ½ÅÀÇ È¨ÆäÀÌÁöÀÇ head ÅÂ±× »çÀÌ¿¡
»ðÀÔÇÏ°í body ÅÂ±× ¾È¿¡ ÀÖ´Â ½ºÅ©¸³Æ® ű׸¦ ÀÚ½ÅÀÇ È¨ÆäÀÌÁöÀÇ ¿øÇÏ´Â
°÷¿¡ ±×´ë·Î »ðÀÔÇÏ¸é µÈ´Ù. |
|
|
|
|