This page last changed on Jul 20, 2012 by wikibot.
ReadExten()
Synopsis
Read an extension into a variable.
Description
Reads a # terminated string of digits from the user into the given variable.
Will set READEXTENSTATUS on exit with one of the following statuses:
- READEXTENSTATUS
- OK - A valid extension exists in $
Unknown macro: {variable} .
-
- TIMEOUT - No extension was entered in the specified time. Also sets $
to "t".
- INVALID - An invalid extension, $
Unknown macro: {INVALID_EXTEN}
, was entered. Also sets $
Unknown macro: {variable}
to "i".
- SKIP - Line was not up and the option 's' was specified.
- ERROR - Invalid arguments were passed.
Syntax
Arguments
- variable
- filename - File to play before reading digits or tone with option i
- context - Context in which to match extensions.
- option
- s - Return immediately if the channel is not answered.
- i - Play filename as an indication tone from your indications.conf or a directly specified list of frequencies and durations.
- n - Read digits even if the channel is not answered.
- timeout - An integer number of seconds to wait for a digit response. If greater than 0, that value will override the default timeout.
Import Version
This documentation was imported from Asterisk Version SVN-trunk-r370328
|