»
EnglishFrenchVietnamese

Print - Week Day Image w/URL - JavaScriptBank.com

Full version: jsB@nk » Image » Week Day Image w/URL
URL: https://www.javascriptbank.com/week-day-image-w-url.html

Week Day Image w/URL © JavaScriptBank.comDisplay a new image every day of the week, with a JavaScript link to a specified URL for that day.

Full version: jsB@nk » Image » Week Day Image w/URL
URL: https://www.javascriptbank.com/week-day-image-w-url.html



JavaScript
<script language="javascript">// Created by: John Hobbs :: http://www.velvetcache.org/window.onload = function() {    var date = new Date();    var today = date.getDay();    var weekdayImg = new Array(7);    weekdayImg[0]="sunday.jpg";    weekdayImg[1]="monday.jpg";    weekdayImg[2]="tuesday.jpg";    weekdayImg[3]="wednesday.jpg";    weekdayImg[4]="thursday.jpg";    weekdayImg[5]="friday.jpg";    weekdayImg[6]="saturday.jpg";    var weekdayLinks=new Array(7);    weekdayLinks[0]="SundayURL.html";    weekdayLinks[1]="MondayURL.html";    weekdayLinks[2]="TuesdayURL.html";    weekdayLinks[3]="WednesdayURL.html";    weekdayLinks[4]="ThursdayURL.html";    weekdayLinks[5]="FridayURL.html";    weekdayLinks[6]="SaturdayURL.html";    document.getElementById('thumbLink').href = weekdayLinks[today];    document.getElementById('thumbImg').src = weekdayImg[today];}</script><!--    This script downloaded from www.JavaScriptBank.com    Come to view and download over 2000+ free javascript at www.JavaScriptBank.com-->


HTML
<b>See example below</b><br><br><a href="#" id="thumbLink"><img border="0" id="thumbImg" alt="Thumbnail Of The Day"></a><!--    This script downloaded from www.JavaScriptBank.com    Come to view and download over 2000+ free javascript at www.JavaScriptBank.com-->