[asterisk-users] setting variable for a DID number

Steve Edwards asterisk.org at sedwards.com
Fri Aug 20 02:09:06 CDT 2010


>> On Thu, 19 Aug 2010, Tino wrote:

>>> But when i call my DID number following dialplans are being executed. 
>>> What i need is to set a variable with one value for one DID number and 
>>> set the same variable with another value for another DID number. Also 
>>> any contexts should be able to use this variable.

> On Thu, Aug 19, 2010 at 11:01 PM, Steve Edwards > 
> <asterisk.org at sedwards.com> wrote:
>>
>>        exten = _x.,n,                  set(FOO=XXX)
>>        exten = _x.,n,                  execif($["${ANI}" =
>> "5555551212"],set,FOO=YYY})

On Thu, 19 Aug 2010, Sherwood McGowan wrote:

> Oh boy...Ok, first, let's get into the root issue here...First, when a 
> variable is set during a call, unless it's defined as a GLOBAL variable, 
> it is only accessible to THE CHANNEL THAT EXECUTED THE SET COMMAND THAT 
> CAUSED THE VARIABLE TO "EXIST".

[snip]

On Thu, 19 Aug 2010, Sherwood McGowan wrote (in an unrelated post):

> I'll leave the "Surely you thought of checking THIS" discussion for when 
> I'm a little less likely to spill Jameson and/or Guiness on me lappy....

I think you got more down your gullet than in your lap :)

The OP said "any contexts" not "any channels."

> Sherwood Mother-F'ing McGowan....
> Because I'm the Mick....and I'm awesome....
>
> P.S. a Sixpack of your choosing to the first person who can correctly 
> identify the person or character the last line of that signature was 
> parodying////

Depending on what you find entertaining, either Miz (WWE) or Barney 
(HIMYM).

Boddington's will be most acceptable. Unfortunately, on this side of the 
pond they only sell it in a 4pack.

-- 
Thanks in advance,
-------------------------------------------------------------------------
Steve Edwards       sedwards at sedwards.com      Voice: +1-760-468-3867 PST
Newline                                              Fax: +1-760-731-3000


More information about the asterisk-users mailing list