Created
October 17, 2011 16:20
-
-
Save mheadd/1292993 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| say('Hello'); | |
| var result = ask('Begin entering a series of digits separated by the star key.', {choices: 'http://path-to/grammar.xml', terminator: '#', mode: 'dtmf', timeout: 5.0}); | |
| log('*** ' + result.value.replace(" ", "") + ' ***'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?xml version="1.0" encoding="ISO-8859-1"?> | |
| <grammar xmlns="http://www.w3.org/2001/06/grammar" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
| xsi:schemaLocation="http://www.w3.org/2001/06/grammar http://www.w3.org/TR/speech-grammar/grammar.xsd" | |
| version="1.0" xml:lang="en-US" root="main"> | |
| <rule id="main" scope="public"> | |
| <item repeat="1-"> | |
| <one-of> | |
| <item>1</item> | |
| <item>2</item> | |
| <item>3</item> | |
| <item>4</item> | |
| <item>5</item> | |
| <item>6</item> | |
| <item>7</item> | |
| <item>8</item> | |
| <item>0</item> | |
| <item>*</item> | |
| </one-of> | |
| </item> | |
| </rule> | |
| </grammar> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment