Name

ImportVar() — Sets a variable based on a channel variable from a different channel

Synopsis

    ImportVar(newvar=channel,variable)

Sets variable newvar to variable as evaluated on the specified channel (instead of the current channel). If newvar is prefixed with _, single inheritance is assumed. If prefixed with _ _, infinite inheritance is assumed.

    ; read the Caller ID information from channel Zap/1
    exten => 123,1,Answer()
    exten => 123,1,ImportVar(cidinfo=Zap/1,CALLERID)

See Also

Set()

Get Asterisk: The Future of Telephony now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.