이미지시계(2)
페이지 정보
본문
<div id=todayDiv style=margin-top:50px;margin-bottom:50px>
<script>
topUrl = "/main/wittazzurri/today/"; // 디렉토리
basicGap = "2px"; // 기본간격
centerGap = "25px"; //중간간격
function todayMode() {
todayTime = new Date();
yearSplit = ("" + todayTime.getFullYear()).split("");
monthSplit = ("0" + (todayTime.getMonth() + 1)).slice(-2).split("");
daySplit = ("0" + todayTime.getDate()).slice(-2).split("");
hoursSplit = ("0" + todayTime.getHours()).slice(-2).split("");
minutesSplit = ("0" + todayTime.getMinutes()).slice(-2).split("");
secondsSplit = ("0" + todayTime.getSeconds()).slice(-2).split("");
for (day = 1; day <= 18; day++) {
if (day <= 4) this["day_" + day] = yearSplit[day - 1];
else if (day == 5) this["day_" + day] = "colon";
else if (day <= 7) this["day_" + day] = monthSplit[day - 6];
else if (day == 8) this["day_" + day] = "colon";
else if (day <= 10) this["day_" + day] = daySplit[day - 9];
else if (day <= 12) this["day_" + day] = hoursSplit[day - 11];
else if (day == 13) this["day_" + day] = "colon";
else if (day <= 15) this["day_" + day] = minutesSplit[day - 14];
else if (day == 16) this["day_" + day] = "colon";
else if (day <= 18) this["day_" + day] = secondsSplit[day - 17];
}
}
todayMode();
for (day = 1; day <= 18; day++) {
if (day == 1) timerGap = "0px";
else if (day == 11) timerGap = centerGap;
else timerGap = basicGap;
document.write("<img id=time_" + day + " src=" + topUrl + this['day_' + day] + ".png style=margin-left:" + timerGap + ";display:block;float:left>");
}
setInterval(function() {
todayMode();
for (day = 1; day <= 18; day++) this['time_' + day].src = topUrl + this['day_' + day] + ".png";
}, 500);
</script>
<div style=clear:both></div>
</div>
<script>
topUrl = "/main/wittazzurri/today/"; // 디렉토리
basicGap = "2px"; // 기본간격
centerGap = "25px"; //중간간격
function todayMode() {
todayTime = new Date();
yearSplit = ("" + todayTime.getFullYear()).split("");
monthSplit = ("0" + (todayTime.getMonth() + 1)).slice(-2).split("");
daySplit = ("0" + todayTime.getDate()).slice(-2).split("");
hoursSplit = ("0" + todayTime.getHours()).slice(-2).split("");
minutesSplit = ("0" + todayTime.getMinutes()).slice(-2).split("");
secondsSplit = ("0" + todayTime.getSeconds()).slice(-2).split("");
for (day = 1; day <= 18; day++) {
if (day <= 4) this["day_" + day] = yearSplit[day - 1];
else if (day == 5) this["day_" + day] = "colon";
else if (day <= 7) this["day_" + day] = monthSplit[day - 6];
else if (day == 8) this["day_" + day] = "colon";
else if (day <= 10) this["day_" + day] = daySplit[day - 9];
else if (day <= 12) this["day_" + day] = hoursSplit[day - 11];
else if (day == 13) this["day_" + day] = "colon";
else if (day <= 15) this["day_" + day] = minutesSplit[day - 14];
else if (day == 16) this["day_" + day] = "colon";
else if (day <= 18) this["day_" + day] = secondsSplit[day - 17];
}
}
todayMode();
for (day = 1; day <= 18; day++) {
if (day == 1) timerGap = "0px";
else if (day == 11) timerGap = centerGap;
else timerGap = basicGap;
document.write("<img id=time_" + day + " src=" + topUrl + this['day_' + day] + ".png style=margin-left:" + timerGap + ";display:block;float:left>");
}
setInterval(function() {
todayMode();
for (day = 1; day <= 18; day++) this['time_' + day].src = topUrl + this['day_' + day] + ".png";
}, 500);
</script>
<div style=clear:both></div>
</div>
- 이전글미니 이퀄 플레이어 - 기본형 21.09.14
- 다음글이미지 시계(1) 21.09.07
댓글목록
등록된 댓글이 없습니다.