Question: JavaScript/CSS/HTML add codes to achieve highlight TimeZone CITY label(s) Given existing codes, add new codes to achieve auto hightlight CITY label(s) with background RED color,

JavaScript/CSS/HTML add codes to achieve highlight TimeZone CITY label(s)

Given existing codes, add new codes to achieve auto hightlight CITY label(s) with background RED color, when the local time of that city or cities is between 900-1800.

JavaScript/CSS/HTML add codes to achieve highlight TimeZone CITY label(s) Given existing codes,

var hr = gmtTime.getHours() + zone var min = gmtTime.getMinutes() var sec = gmtTime.getSeconds()

if (hr >= 24){ hr = hr-24 day -= -1 } if (hr monthDays[month]){ day = 1 if(month == 11){ month = 0 year -= -1 } else{ month -= -1 } }

if (dst == 1){ hr -= -1 if (hr >= 24){ hr = hr-24 day -= -1 } if (hr monthDays[month]){ day = 1 if(month == 11){ month = 0 year -= -1 } else{ month -= -1 } } return monthArray[month] + " " + day + ", " + year + " " + hr + ":" + min + ":" + sec } else{ return monthArray[month] + " " + day + ", " + year + " " + hr + ":" + min + ":" + sec } }

function worldClockZone(){ document.getElementById("UTC").innerHTML = worldClock(0, "Greenwich") document.getElementById("CITY2").innerHTML = worldClock(+10, "Greenwich") document.getElementById("CITY1").innerHTML = worldClock(-5, "Greenwich") document.getElementById("CITY3").innerHTML = worldClock(+1, "Greenwich")

setTimeout("worldClockZone()", 1000) } window.onload=worldClockZone;

//-->

.hrow { vertical-align: middle; width: 100%; }

.hrow td { padding: 5px; width: 140px; background-color: #D2D2D2; border: 2px solid #D2D2D2; border-collapse: collapse; font-family:arial; color: #0A0A0A; text-align: center; font-weight: normal; }

.hrow td:hover { background-color: #B2FF4B; color: #222222; border: 2px solid #B2FF4B; }

.hrow td:hover h3 { color: #0A0A0A; }

h3 { text-transform: uppercase; display: inline; color: #0A0A0A; font-family: arial; }

CITY1

UTC

CITY2

CITY3

Time Zones EDIT HELP CITY1 September 15, 2018 18:44:36 UTC Scptember 15, 2018 23:44.36 CITY2 Scptember 16, 2018 944:36 CITY3 September 16, 2018 0:44:36

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!