Hello Nabeel:

I am aware of the 'n' numbering system...  but was not aware that it could be 
used in a GotoIf and other Goto/Loop statements.   What happens if in your  2nd 
line marked,  " exten => 1001,n,Goto(here) " needs to go to the last line, that 
is the 5th line?   With the  " exten => 1001,n,Goto(5) " on the 2nd line, 
direct Asterisk to go to the 5th line, even though it's marked 'n' ?

I was under the impression 'n' could be used only if the dial plans are drawn 
sequentially & simple dialplans.  I did not know the 'n' could be used in a 
GotoIF statements.  Input from you and anyone here on this regard would be 
greatly appreciated since I have complex dial plans with the GotoIF statement, 
not just Goto statement... and implementing the 'n', would save a LOT OF hassle.

Personally I think numbering with literal ascending numbers, vs. the 'n',  has 
greater advantage in complex dial plans, comprising with AGI scripts, Goto & 
GotoIF statements.  It greatly improves debuging and tweaking out your codes in 
debug mode.

Would love to hear the thoughts of the * minds :).

Cheers!


 
----- Original Message ----- 
From: "Nabeel Jafferali" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Monday, May 29, 2006 10:10 PM
Subject: RE: [on-asterisk] Asterisk Horror Stories


> Use this instead:
> 
> exten => 1001,1,blah
> exten => 1001,n,Goto(here)
> exten => 1001,n,blah
> exten => 1001,n(here),blah
> exten => 1001,n,blah
> 
> Nabeel
> 
>> -----Original Message-----
>> From: Reza - Asterisk Enthusiast [mailto:[EMAIL PROTECTED] 
>> Sent: May 29, 2006 9:49 PM
>> To: [email protected]
>> Subject: Re: [on-asterisk] Asterisk Horror Stories
>> 
>> My horror story is with context numbering.   So hopefully 
>> this tip will help all those curious.
>>  
>> Lets say items in your context are as follows:
>>  
>> exten => 1001,1,bla bla bla
>> exten => 1001,2,bla bla bla
>> exten => 1001,3,bla bla bla
>> exten => 1001,4,bla bla bla
>> exten => 1001,6,bla bla bla
>>  
>> Note that I have a total of 5 line of codes.  The last line 
>> is actually numbered 6.   In my experience, MAKE SURE, that 
>> the context/dial plan in question, is properly numbered.   In 
>> this particular example it should have been exten => 
>> 1001,5,bla bla bla.
>>  
>> The above example is intended for those who actually use the 
>> GotoIf statement within their dial plans.  I spent an entire 
>> day trying to solve an issue, which was caused by my own 
>> stupidity, not paying attention to the numbering.  Even if 
>> the GotoIf statement is not used, make sure you number them 
>> well...  Have your dial plans numbered properly otherwise you 
>> will experience STRANGE results ;).
>>  
>> I pi$$ed away an entire day, the time which I could have 
>> otherwise spent drinking pints of beer!  Moral of the story: 
>> after the number 4 comes 5, not 6 ;).
>>  
>> Cheers!
>>  
>>  
>> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
>

Reply via email to