[Asterisk-Users] Goto command question
Eric "ManxPower" Wieling
eric at fnords.org
Sat Oct 15 10:03:25 MST 2005
Mohamed A. Gombolaty wrote:
> Dear All,
>
> I have this question regarding goto command, I amusing Asterisk cvs head
> version, and I am trying to put a goto statement to send the user to
> another extension that contains the extension he is dialing here is how I
> am doing it :
>
> exten => 2x.,1,setgroup(outgoing)
> exten => 2x,2,checkgroup(2)
> exten => 2x.,3,goto(another-context, ${EXTEN},1)
> exten => 2x.,104,hangup
>
> but the result is always it hangs up I don't know if this goto statement is
> correct or not, can anyone lead me to the right way to make this statement?
First of all patterns must start with _
exten => _2X.,1,setgroup(outgoing)
Second you are using different patterns
exten => _2X.,1,setgroup(outgoing)
Is NOT the same as
exten => _2X,2,checkgroup(2)
The first pattern is _2X. the second pattern is _2X
Third, do not put spaces after commas.
Try this:
exten => _2X.,1,SetGroup(outgoing)
exten => _2X.,2,CheckGroup(2)
exten => _2X.,3,Goto(another-context,${EXTEN},1)
exten => _2X.,104,Hangup
More information about the asterisk-users
mailing list