${EXTEN} is the extension you are currently at.
exten => s,1,Goto(444) ; ${EXTEN} = s exten => 444,1,NoOp(bleh) ; ${EXTEN} = 444 exten => someotherextension,1,NoOp() ; $EXTEN = someotherextension -Matthew ----- Original Message ----- From: "Robert Rozman" <[EMAIL PROTECTED]> To: "Asterisk Users Mailing List - Non-Commercial Discussion" <asterisk-users@lists.digium.com> Sent: Thursday, March 03, 2005 3:11 PM Subject: [Asterisk-Users] Why ${EXTEN} variable changes after Goto ? > Hi, > > I'm trying to implement dynamic routing of incoming calls to local extension > if previous outgoing call was unanswered. > But after I do Goto to s-NOANSWER, variable ${EXTEN} changes to > 's-NOANSWER'. I guess this is normal, but I don't understand why ? How to > workaround on this one ? > > Thanks in advance, > > regards, > > Rob. > > [outbound-capi-ISDN] > exten => _0.,1,NoOp(Calling ISDN number ${EXTEN:1} on CAPI/7104370 from > ${CALLERIDNUM}) > exten => _0.,2,Dial,CAPI/7104370:b${EXTEN:1}|10|Tt > exten => _0.,3,Goto(s-${DIALSTATUS},1) > exten => _0.,103,NoOp(Calling ISDN number ${EXTEN:1} on CAPI/7104371) > exten => _0.,104,Dial,CAPI/7104371:b${EXTEN:1}|30|Tt > exten => _0.,105,Goto(s-${DIALSTATUS},1) > exten => _0.,205,Macro(outisbusy) > > exten => s-NOANSWER,1,NoOp(NOANSWER - Setting dynamic autoroute for ISDN > number ${EXTEN:1} to local ext. ${CALLERIDNUM}) > exten => s-NOANSWER,2,DBput(DYNAMIC/${EXTEN}=${CALLERIDNUM}) > exten => s-NOANSWER,3,Congestion > > exten => _s-.,1,Congestion > exten => _s-.,2,Macro(hangupcall) > > _______________________________________________ > Asterisk-Users mailing list > Asterisk-Users@lists.digium.com > http://lists.digium.com/mailman/listinfo/asterisk-users > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-users _______________________________________________ Asterisk-Users mailing list Asterisk-Users@lists.digium.com http://lists.digium.com/mailman/listinfo/asterisk-users To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users