[Asterisk-Users] 1 extension entry for multiple purposes?

Adam Goryachev mailinglists at websitemanagers.com.au
Mon Sep 20 18:59:58 MST 2004


On Tue, 2004-09-21 at 08:14, Matthew Boehm wrote:
> OK. So I removed all the callerid= from the sip.conf and Wiley's fix works
> perefectly. But I am back to where if I call out, the caller id shows up as
> my extension only.
> 
> My fix, that didn't work:
> 
> [global-outgoing]
>  exten => s,1,SetCIDNum(212-433-3344)
>  exten => _9212XXXXXXX,2,Dial(SIP/${EXTEN}@<router IP>,15,tr)
>  exten => _91XXXXXXXXXX,2,Dial(SIP/${EXTEN}@<router IP>,15,tr))
> 
> I figured that if I tacked an 's' extension before the pattern matching,
> every outgoing pattern below the 's' would get that CID. But that didn't
> work.

Read on for the answer, but first, please trim your posts, you don't
need to include 200 lines of quoted text, just the relevant portions.

Now, you don't seem to understand how extensions work. Look on the wiki
for some additional examples, but for now, once you choose an extension
(s, i, or 243284 or _XXXX) then you will move through the priorities
within that extension until the caller dials a new extension, or you hit
a goto of some sort.
Also, priority must be consecutive order starting at 1.
 exten => _9212XXXXXXX,1,SetCIDNum(212-433-3344)
 exten => _9212XXXXXXX,2,Dial(SIP/${EXTEN}@<router IP>,15,tr)
 exten => _91XXXXXXXXXX,1,SetCIDNum(212-433-3344)
 exten => _91XXXXXXXXXX,2,Dial(SIP/${EXTEN}@<router IP>,15,tr))

That should work much better for you.

PS, this post is not meant to flame, or be derogatory, but a push to
encourage you to read/learn more.

Regards,
Adam





More information about the asterisk-users mailing list