[asterisk-commits] lmadsen: trunk r227361 - /trunk/configs/extensions.conf.sample
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Tue Nov 3 13:25:23 CST 2009
Author: lmadsen
Date: Tue Nov 3 13:25:18 2009
New Revision: 227361
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=227361
Log:
Additional fixes to the extensions.conf.sample file.
Update the extensions.conf.sample [stdexten] context so that we use the
variable instead of requiring it to be passed explicitly. Also updated uses of
the [stdexten] context throughout.
(closes issue #15858)
Reported by: pprindeville
Patches:
stdexten-context-update.txt uploaded by lmadsen (license 10)
Tested by: pprindeville
Modified:
trunk/configs/extensions.conf.sample
Modified: trunk/configs/extensions.conf.sample
URL: http://svnview.digium.com/svn/asterisk/trunk/configs/extensions.conf.sample?view=diff&rev=227361&r1=227360&r2=227361
==============================================================================
--- trunk/configs/extensions.conf.sample (original)
+++ trunk/configs/extensions.conf.sample Tue Nov 3 13:25:18 2009
@@ -236,7 +236,7 @@
;
; List canonical entries here
;
-;exten => 12564286000,1,Gosub(stdexten(6000,IAX2/foo))
+;exten => 12564286000,1,Gosub(6000,stdexten(IAX2/foo))
;exten => 12564286000,n,Goto(default,s,1) ; exited Voicemail
;exten => _125642860XX,1,Dial(IAX2/otherbox/${EXTEN:7})
@@ -406,9 +406,9 @@
[stdexten]
;
; Standard extension subroutine:
-; ${ARG1} - Extension
-; ${ARG2} - Device(s) to ring
-; ${ARG3} - Optional context in Voicemail (if empty, then "default")
+; ${EXTEN} - Extension
+; ${ARG1} - Device(s) to ring
+; ${ARG2} - Optional context in Voicemail (if empty, then "default")
;
; Note that the current version will drop through to the next priority in the
; case of their pressing '#'. This gives more flexibility in what do to next:
@@ -422,9 +422,9 @@
; previous value (before being declared as LOCAL()) upon Return.
;
exten => _X.,50000(stdexten),NoOp(Start stdexten)
-exten => _X.,n,Set(LOCAL(ext)=${ARG1})
-exten => _X.,n,Set(LOCAL(dev)=${ARG2})
-exten => _X.,n,Set(LOCAL(cntx)=${ARG3})
+exten => _X.,n,Set(LOCAL(ext)=${EXTEN})
+exten => _X.,n,Set(LOCAL(dev)=${ARG1})
+exten => _X.,n,Set(LOCAL(cntx)=${ARG2})
exten => _X.,n,Set(LOCAL(mbx)="${ext}"$["${cntx}" ? "@${cntx}" :: ""])
exten => _X.,n,Dial(${dev},20) ; Ring the interface, 20 seconds maximum
@@ -527,7 +527,7 @@
;
exten => 1234,1,Playback(transfer,skip) ; "Please hold while..."
; (but skip if channel is not up)
-exten => 1234,n,Gosub(stdexten(1234,${GLOBAL(CONSOLE)}))
+exten => 1234,n,Gosub(${EXTEN},stdexten(${GLOBAL(CONSOLE)}))
exten => 1234,n,Goto(default,s,1) ; exited Voicemail
exten => 1235,1,Voicemail(1234,u) ; Right to voicemail
@@ -644,11 +644,11 @@
;exten => 6391,1,Dial(JINGLE/asterisk at digium.com/mogorman at astjab.org) ;Dial via jingle using asterisk as the transport and calling mogorman.
;exten => 6394,1,Dial(Local/6275/n) ; this will dial ${MARK}
-;exten => 6275,1,Gosub(stdexten(6275,${MARK}))
+;exten => 6275,1,Gosub(${EXTEN},stdexten(${MARK}))
; assuming ${MARK} is something like DAHDI/2
;exten => 6275,n,Goto(default,s,1) ; exited Voicemail
;exten => mark,1,Goto(6275,1) ; alias mark to 6275
-;exten => 6536,1,Gosub(stdexten(6236,${WIL}))
+;exten => 6536,1,Gosub(${EXTEN},stdexten(${WIL}))
; Ditto for wil
;exten => 6536,n,Goto(default,s,1) ; exited Voicemail
;exten => wil,1,Goto(6236,1)
@@ -715,10 +715,10 @@
;
;[acme-extens]
;include => stdexten
-;exten => 111,1,Gosub(stdexten(111,SIP/pete_1,acme))
+;exten => 111,1,Gosub(111,stdexten(SIP/pete_1,acme))
;exten => 111,n,Goto(s,exten)
;
-;exten => 112,1,Gosub(stdexten(112,SIP/nancy_1,acme))
+;exten => 112,1,Gosub(112,stdexten(SIP/nancy_1,acme))
;exten => 112,n,Goto(s,end)
;
; end of acme example
More information about the asterisk-commits
mailing list