[asterisk-users] Read one or X DTMF
Tony Mountifield
tony at softins.clara.co.uk
Fri Sep 12 11:29:30 CDT 2008
In article <48CA84AA.70601 at micnes.com>,
Ruddy Gbaguidi <plugworld at micnes.com> wrote:
> Hi all
> I'm just having a problem now and I don't have any idea how to do this.
>
> It is pretty simple. When a customer calls, to speed up the navigation
> in the dialplan, I want something like
>
> "Welcome. Please enter your 10 digit customer number or press * to register"
>
> So, I want to read up to 10 digits, and if the user press *, I want to
> go to the next extension.
>
> Do you have an idea ??
One possibility:
[getnumber]
exten => s,1,Background(please-enter-num-or-star)
exten => s,n,Waitexten(30)
exten => *,1,Goto(register,s,1)
exten => _X*,1,Goto(register,s,1)
exten => _XX*,1,Goto(register,s,1)
exten => _XXX*,1,Goto(register,s,1)
exten => _XXXX*,1,Goto(register,s,1)
exten => _XXXXX*,1,Goto(register,s,1)
exten => _XXXXXX*,1,Goto(register,s,1)
exten => _XXXXXXX*,1,Goto(register,s,1)
exten => _XXXXXXXX*,1,Goto(register,s,1)
exten => _XXXXXXXXX*,1,Goto(register,s,1)
exten => _XXXXXXXXXX,1,Do whatever
exten => _XXXXXXXXXX,n,You want to do with
exten => _XXXXXXXXXX,n,A 10-digit customer number
[register]
exten => s,1,Start registration process
Hope that helps
Cheers
Tony
--
Tony Mountifield
Work: tony at softins.co.uk - http://www.softins.co.uk
Play: tony at mountifield.org - http://tony.mountifield.org
More information about the asterisk-users
mailing list