Using IFTIME with a specific timezone in Asterisk dialplan

Hi everyone,
I’m using the IFTIME function in the Asterisk dialplan to evaluate whether the current time falls within a specific interval. For example:

dialplan eval function IFTIME(07:00-16:30,*,*,*?true:false) 

This works fine, but now I’d like to perform the same check based on a specific timezone (e.g., not the server’s local time).

Is there a way to configure IFTIME or use another method in the dialplan to evaluate the time interval based on a specific timezone?

Thanks in advance!

Timespec is the same as GotoIfTime[1] so that format should work, meaning the last argument which is optional is the timezone.

[1] GotoIfTime - Asterisk Documentation

Thanks for reply. What is the format of timezone I have to use?

It’s based on the naming in /usr/share/zoneinfo

Perfect it works like a charm.
Thank you so much!

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.