[Asterisk-Users] Any way to _always_ execute certain commands in a
dialplan context?
Kevin P. Fleming
kpfleming at backtobasicsmgmt.com
Thu Sep 2 19:42:13 MST 2004
I've got a need to do something like the following:
[foo-context]
exten => _.,1,SetCIDNum(123)
exten => _.,2,SetCIDName(XYZ)
include => local
include => tollfree
But of course, this example won't work. The goal here is this: if a call
ends up being handled by the "local" or "tollfree" contexts, I want
those SetCID*** commands executed. Otherwise, I don't want them
executed. I don't want to embed them into the local/tollfree contexts
themselves, because then I'd have to figure out some way to store the
"123" and "XYZ" values so that they could be used by commands in those
contexts.
Essentially, what I want to do is override the CALLERIDNUM/CALLERIDNAME
data for calls that are directed outside the PBX, and leave it alone for
calls inside the PBX. That way internal users can see "John Q. Smith
<322>" (different for each extension), but outside callees see "Smithco
Widgets <602-555-1212>" (which would be identical for all of the
extensions that can make outside calls).
More information about the asterisk-users
mailing list