GotoIfTime(condition?destination)
Full arguments reference
conditionrequiredtimesrequiredweekdaysrequiredmdaysrequiredmonthsrequiredtimezone
destinationrequiredlabeliftrue- Continue at labeliftrue if the condition is true. Takes the form similar to Goto() of [[context,]extension,]priority.labeliffalse- Continue at labeliffalse if the condition is false. Takes the form similar to Goto() of [[context,]extension,]priority.
This application will set the context, extension, and priority in the channel structure based on the evaluation of the given time specification. After this application completes, the pbx engine will continue dialplan execution at the specified location in the dialplan. If the current time is within the given time specification, the channel will continue at labeliftrue. Otherwise the channel will continue at labeliffalse. If the label chosen by the condition is omitted, no jump is performed, and execution passes to the next instruction. If the target jump location is bogus, the same actions would be taken as for Goto. Further information on the time specification can be found in examples illustrating how to do time-based context includes in the dialplan.
conditionrequiredtimesrequiredweekdaysrequiredmdaysrequiredmonthsrequiredtimezone
destinationrequiredlabeliftrue- Continue at labeliftrue if the condition is true. Takes the form similar to Goto() of [[context,]extension,]priority.labeliffalse- Continue at labeliffalse if the condition is false. Takes the form similar to Goto() of [[context,]extension,]priority.
User Notes
Know a tip or gotcha for this topic? Share it below and help others.
Contribute a note
Share a tip, gotcha, or practical example. Keep it under 2000 characters. No questions (use the Asterisk community forums for support). Wrap code in backticks.