[Asterisk-Users] Feedback request: AGI GET DATA change - termination digits

John Todd jtodd at loligo.com
Sat Oct 18 17:10:47 MST 2003


>** REPOST: A week later and no feedback - am I the only one
>** who'd find this functionality useful? No other AGI stuff
>** out there needing something similar?
>
>I'd like some feedback on potentially submitting a request (and probably a
>patch too) to change the way the AGI command GET DATA works.
>
>Right now, # terminates the entry, which is then returned with the #
>stripped off the end. What I'd like is to allow user configurable
>termination digits, which are not stripped off the end.
>
>Reasoning: Some entries you'd like to terminate with #. Right now it's fine,
>you can tell if # was pressed or not by looking for the lack of a (timeout)
>entry in the returned result. You may want to allow * to cancel an entry.
>This is not possible right now. Systems I've coded previously allow # to
>terminate and complete a digit entry, * to correct an incorrect entry
>(playing the prompt again and restarting digit collection). Pressing  * with
>no prior digit entry cancels the step and returns to the previous menu.
>
>I guess there's a compatibility issue with stuff that's out there already
>but if it was an optional 4th parameter this would be backwards compatible.
>
>Proposed new syntax:
>   GET DATA <filename> <timeout> <maxdigits> <terminator>
>
>If terminator is specified (and it may be multicharacter, like "*#" to give
>me the functionality above), return the digit string collected so far,
>including the terminating digit. The calling app can strip the trailing
>character if needed.
>
>Thoughts?
>
>Cheers
>Paul

I can't comment on the usefulness of creating this additional syntax 
in an AGI (though it does seem like a useful shorthand method to 
recognize terminators and replay digits) but some of the same 
comments have been discussed in the bugtracker for dialplan routines.

see: http://bugs.digium.com/bug_view_page.php?bug_id=0000181

JT



More information about the asterisk-users mailing list