Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //CLI-->pressing option "2" doesn't call SIP/40, instead it goes to extension 2 in context local, yet i thought i should go to extension 2 in context senteLtdMenu. How can i achieve that??
- -- Executing [750@local:1] Answer("SIP/50-00000007", "") in new stack
- -- Executing [750@local:2] BackGround("SIP/50-00000007", "user_recordings/senteVoiceMenu") in new stack
- -- <SIP/50-00000007> Playing 'user_recordings/senteVoiceMenu.slin' (language 'en')
- == CDR updated on SIP/50-00000007
- -- Executing [2@local:1] BackGround("SIP/50-00000007", "demo-moreinfo") in new stack
- -- <SIP/50-00000007> Playing 'demo-moreinfo.gsm' (language 'en')
- -- Executing [2@local:2] Goto("SIP/50-00000007", "s,instruct") in new stack
- -- Goto (local,s,6)
- -- Executing [s@local:6] BackGround("SIP/50-00000007", "demo-instruct") in new stack
- -- <SIP/50-00000007> Playing 'demo-instruct.gsm' (language 'en')
- //sip.conf(part of it)
- [50]
- ;this user enters local context in extensions.conf
- context=local
- //extensions.conf(just part of it)
- [local]
- ;include the IVR context
- include=>senteLtdMenu
- //IVR context in extension.conf
- [senteLtdMenu]
- exten => 750,1,Answer()
- same=>n(sente_prompt),Background(user_recordings/senteVoiceMenu);play a sound "main menu" while waiting for user input
- same=>n,WaitExten(60);wait for 5 seconds
- ;respond to the prompts
- exten=>1,1,Dial(SIP/30);say "1" back to the user when they press 1
- same=>n,GoSub(subTimeControl,s,1(50))
- same=>n,Goto(senteLtdMenu,750,sente_prompt);this is a loop or like a recursive function call
- exten=>2,1,Dial(SIP/40);say "2" back to the user whey they press 2
- same=>n,Goto(senteLtdMenu,750,sente_prompt);this is a loop or like a recursive function call
- exten=>3,1,Dial(SIP/perezdroid);call perez's droid
- ;handle invalid inputs
- exten=>i,1,Playback(pbx-invalid);invalid inputs are sent to extension i
- same=>n,Goto(senteLtdMenu,750,sente_prompt);go back and let the user input correct entries
- ;handle timemouts
- exten=>t, 1,Playback(vm-goodbye);when system has timed out, dialplan is sent to extension t
- same=>n,Hangup();just hangup
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement