Hi
I wanted to use Timer to show Dialog at a certain times during the day. Like when it is: Office After-Hours.
But it does not work for me. Can you check please?
DEMO:
https://easyupload.io/s4k12s
Also, I would like to ask if there is an option to start a Timer function at a certain times of day only, but using Select: Conditions?
DEMO:
https://easyupload.io/fmnlu6
Thanks
Timer function: Time Range, does Not work for me
Forum rules
IMPORTANT NOTE!!
DO YOU HAVE A QUESTION OR PROBLEM AND WANT QUICK HELP?
THEN PLEASE SHARE A "DEMO" PROJECT.
PLEASE READ THE FORUM RULES BEFORE YOU POST:
http://www.wysiwygwebbuilder.com/forum/viewtopic.php?f=12&t=1901
MUST READ:
http://www.wysiwygwebbuilder.com/getting_started.html
WYSIWYG Web Builder FAQ
IMPORTANT NOTE!!
DO YOU HAVE A QUESTION OR PROBLEM AND WANT QUICK HELP?
THEN PLEASE SHARE A "DEMO" PROJECT.
PLEASE READ THE FORUM RULES BEFORE YOU POST:
http://www.wysiwygwebbuilder.com/forum/viewtopic.php?f=12&t=1901
MUST READ:
http://www.wysiwygwebbuilder.com/getting_started.html
WYSIWYG Web Builder FAQ
Re: Timer function: Time Range, does Not work for me
The 'start time' should be lower than the 'end time'.
Sorry, there is no standard option for this.I would like to ask if there is an option to start a Timer function at a certain times of day only, but using Select: Conditions?
Re: Timer function: Time Range, does Not work for me
I don' understand this so good. So If my bussines hours are 9-21H, so I don't work from 21H untill the next day 9AM, and I want to show the Dialog when I am NOT working ONLY, what should I do?
How do I set it up? Do I then need two timers and what should I enter in each Timer?
Please help.
Thanks.
Re: Timer function: Time Range, does Not work for me
Sorry, that will not work. It will only work for a time range on the same day.
The range is from 12:00:00 AM to 11:59:59 PM
The range is from 12:00:00 AM to 11:59:59 PM
- wwonderfull
-
- Posts: 1576
- Joined: Fri Aug 21, 2020 8:27 am
- Contact:
Re: Timer function: Time Range, does Not work for me
This is a bit complex so I think it may require custom codes to address a solution.
Re: Timer function: Time Range, does Not work for me
Maybe you can reverse the logic?
Instead of showing a dialog when you're not working, instead hide the dialog when you are working.
Instead of showing a dialog when you're not working, instead hide the dialog when you are working.
Re: Timer function: Time Range, does Not work for me
I found a bug in the extension that is causing the issue that I am facing.
In auto start option when timer checks the correct time on document load the endTime var is never set to the desired end time instead it was made to set the startTime
In auto start option when timer checks the correct time on document load the endTime var is never set to the desired end time instead it was made to set the startTime
Code: Select all
document.addEventListener('DOMContentLoaded', function(event)
{
var startTime = new Date();
startTime.setHours(10, 0, 0);
var endTime = new Date();
startTime.setHours(20, 57, 8); // <-- See?
var currentTime = new Date();
if (currentTime >= startTime && currentTime <= endTime)
{
TimerStartTimer1();
}
});
Code: Select all
document.addEventListener('DOMContentLoaded', function(event)
{
var startTime = new Date();
startTime.setHours(10, 0, 0);
var endTime = new Date();
endTime.setHours(20, 57, 8); // <-- Has to be like this!
var currentTime = new Date();
if (currentTime >= startTime && currentTime <= endTime)
{
TimerStartTimer1();
}
});
Re: Timer function: Time Range, does Not work for me
This has been fixed in the latest build (12/25/2023).load the endTime var is never set to the desired end time instead it was made to set the startTime