----- Original Message ----- From: "Gary Franczyk" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Tuesday, January 20, 2004 10:51 AM Subject: [Asterisk-Users] Enter Pin followed by Pound key
> Im trying to create a custom application via the AGI. I want to > authenticate the users that dial in with a userid and pin. However, the > number of digits in the PIN and userid are variable, and therefore I need to > allow the user to "press enter" by hitting the pound key. How would I > accomplish this in the AGI? > > stream_file doesnt seem to work, since it only allows one digit to be > pressed. > get_data seems to only allow a fixed number of digits to be entered. Sorry if I'm speaking out of school, as I have never programmed AGIs, but from what you described, the stream_file taking one digit at a time should be sufficient. string entry while (keypressed != #) { entry += keypressed } In this way, you could "build up" your string of digits. Don't know how AGI is working specifically, but hopefully this will trigger some thought or idea. > > > Thanks > Gary Franczyk > > _______________________________________________ > Asterisk-Users mailing list > [EMAIL PROTECTED] > http://lists.digium.com/mailman/listinfo/asterisk-users > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-users > _______________________________________________ Asterisk-Users mailing list [EMAIL PROTECTED] http://lists.digium.com/mailman/listinfo/asterisk-users To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users