I need some help with a javascript
I need to create a script that checks a time range (costa rica time) and then displays the following:
a static image from 7pm to 5am
a video streaming from 5.01am to 6.59pm
I prepared this solution but I don't know how to show the static image and the streaming:
<script type="text/javascript">
var d = new Date();
var n = d.getHours(); //get the current local time's hour in military time (1..23)
//If the time is greater than or equal to 7pm or less than or equal to 7am
if (n >= 19 || n <= 5)
{
show image
}
else
{
stream video
}
Thanks