[Asterisk-Users] Detect alternate line in Broadvoice inbound context

Mark Hulber asterisk-admin at hulber.com
Mon Nov 21 20:50:40 MST 2005


Ok, your solution does work but in looking at my console output I saw that 
SIPGetHeader was deprecated for the new dialplan function SIP_HEADER.  Below is 
my modification.  You don't need a priority+101.

exten => 2129999999,1,Set(Var_Alert=${SIP_HEADER(Alert-Info)})
exten => 2129999999,n,GotoIf($["${Var_Alert}" = 
"<http://127.0.0.1/Bellcore-dr3>"]?x-9169999999,1:x-2129999999,1)

In this case, the 212 number is the primary number.

Thanks,

MARK.

Samy Antoun wrote:
> Mark,
> 
> 1. Make sure that SIPGetHeader application is registered
> CLI> show application SIPGetHeader
> if it is registered you'll get
>   -= Info about application 'SIPGetHeader' =-
> [Synopsis]
> Get a SIP header from an incoming call
> [Description]
>   SIPGetHeader(var=headername):
> Sets a channel variable to the content of a SIP header
> Skips to priority+101 if header does not exist
> Otherwise returns 0
> If not,
> Your application(s) is (are) not registered
> 
> If the application is not registered, I can't recommend anything for
> you, I had an Asterisk system with ver 1.0 (no SIPGetHeader) and I
> tried to patch it with any of the following with no luck:
> http://bugs.digium.com/bug_view_page.php?bug_id=0002838 
> http://bugs.digium.com/view.php?id=2924
> 
> If you have it registered, here is a sample of my setup:
> [bvdr]
> exten => s,1,Answer 
> exten => s,2,DigitTimeout(5) 
> exten => s,3,ResponseTimeout(10) 
> exten => s,4,SIPGetHeader(Var_Alert=Alert-Info) 
> exten => s,5,GotoIf($["${Var_Alert}" =
> "<http://127.0.0.1/Bellcore-dr3>"]?ext-local,320,1) 
> exten => s,6,Goto(ext-local,200,1)
> 
> This setup for ONE Distinctive Ring only (Bellcore-dr3), if you have
> more than one, you can use "sip debug" to retrieve the header
> information
> 
> The BEST reference for this subject is:
> http://voxilla.com/PNphpBB2-viewtopic-t-3935-highlight-dring1.html
> 
> Hope this helps
> 
> 
> 
> 
> 		
> __________________________________ 
> Start your day with Yahoo! - Make it your home page! 
> http://www.yahoo.com/r/hs
> 
> 
> 	
> 		
> __________________________________ 
> Yahoo! Mail - PC Magazine Editors' Choice 2005 
> http://mail.yahoo.com



More information about the asterisk-users mailing list