I am searching for a way to auto play a music file at a specific time of the week.
E.g. on Mondays at 12 pm.
If that is not possible with weekdays, only hours would be also ok, like every day at 12 pm, but it would be great if it would work with weekdays.
After playing the file from start to end, it should stop and wait for the next turn, e.g. next Monday at 12pm.
I tried this code, but it didn't work for me:
JS:
<script>
var d = new Date();
var m = d.getMinutes();
var h = d.getHours();
if (h == 17 && m == 00){
var sound = document.getElementById(sound1);
sound.Play();
}
</script>
HTML:
<embed src="notify.mp3" autostart="false" width="0" height="0" id="sound1"
enablejavascript="true">
Thank you a lot in advance!!