[asterisk-users] dialplan number matching

Vieri rentorbuy at yahoo.com
Fri Jul 17 14:43:28 CDT 2009



--- On Fri, 7/17/09, Danny Nicholas <danny at debsinc.com> wrote:

> Assuming you are using 4 digit
> extensions, this syntax would be:
> - exten => _ZXX3,n,...
> For 3 digits
> - exten => _ZX3,n,...
> The . is a wildcard that says "take rest of number, so
> anything after that
> is irrelevant.

Thanks but the extensions have a variable length (cannot determine in advance) so I can't use that logic.
It's for matching international calls (variable length and I can't keep a database with all possible patterns worldwide) in case of "early-dial"/"address incomplete" SIP clients (I recently exposed this issue on this mailing list).

Anyway, thanks for the feedback.

Vieri

> -----Original Message-----
> From: asterisk-users-bounces at lists.digium.com
> [mailto:asterisk-users-bounces at lists.digium.com]
> On Behalf Of Vieri
> Sent: Friday, July 17, 2009 4:11 AM
> To: asterisk-users at lists.digium.com
> Subject: [asterisk-users] dialplan number matching
> 
> 
> Hi,
> 
> How can I match an extension "ending with 3" (just an
> example but applicable
> to any other digit, including * or #)?
> 
> exten => _ZX.3,n,...
> 
> exten => _ZX.#,n,...
> 
> (the above does not work)
> 
> Can regular expressions be used in the standard dialplan
> (end with: "$")?
> 
> Thanks,
> 
> Vieri
> 


      



More information about the asterisk-users mailing list