For me there was. "enter the value or press # to skip" because it's optional... seems a very possible use-case. It's an IVR for gathering information, not navigating a menu.
-Avi


On Mon, Jun 18, 2012 at 6:09 PM, Michael Collins <msc@freeswitch.org> wrote:
But but but the wiki says! The wiki just CAN'T be wrong! ;) Actually, according to switch_ivr_play_say.c it looks like you can have a min_digits of "0". Still, I'd make the min digits "1" unless there's a compelling reason to want zero digits.
-MC


On Mon, Jun 18, 2012 at 8:00 AM, Avi Marcus <avi@avimarcus.net> wrote:
Uhm I thought I just wrote code that did that last week in lua. Seemed to work GREAT.

if(phone_required==true) then 
...
else 
phone_min=0 --no minimum on the match length
end
phone=session:playAndGetDigits(phone_min, phone_max, 3, 20000, "#", "phrase:cc_phone_prompt:"..phone_skip, "phrase:cc_invalid_entry","\\d{"..phone_min..","..phone_max.."}");

-Avi


On Mon, Jun 18, 2012 at 5:55 PM, Michael Collins <msc@freeswitch.org> wrote:


The problem is with
                confirmkey = session:playAndGetDigits(0, 1, 1, 1000,
"#", confPrompt, "", "\\d|\\*")
 
It complains of "Invalid Args" (and doesn't say anything). All it has to
do is read out the number that it's intending to call, allowing the user
to change their mind by hitting *.


You can't have an argument of "0" for the minimum number of digits. See this page for details on play_and_get_digits args:
http://wiki.freeswitch.org/wiki/Misc._Dialplan_Tools_play_and_get_digits

-MC



_________________________________________________________________________
Professional FreeSWITCH Consulting Services:
consulting@freeswitch.org
http://www.freeswitchsolutions.com

FreeSWITCH-powered IP PBX: The CudaTel Communication Server
http://www.cudatel.com

Official FreeSWITCH Sites
http://www.freeswitch.org
http://wiki.freeswitch.org
http://www.cluecon.com

Join Us At ClueCon - Aug 7-9, 2012

FreeSWITCH-users mailing list
FreeSWITCH-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org