KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I am trying to use the new x-webkit-speech function in a simple HTML/JavaScript extension in Google Chrome . I, however, have tried and tried looking at a bunch of examples and cannot get it to successfully call the function. I have seen other people do it, and I don't really get why I cannot. I put the JavaScript code into a separate file, but I include using <script src="filename.js"> this is my line for the x-webkit-speech.... <input id="speechInput" type="text" style="font-size:25px;" x-webkit-speech speech onwebkitspeechchange="onChange()" /> Now, if I change onChange() to alert(this.value) , it executes an alert box with the value of the speech input in it. So I really do not understand why I cannot just call another function. I am not the greatest JavaScript or HTML programmer, but I have researched this a great deal. Everyone defines things differently, and since there is no solid API, it is hard to really know who has the correct form, because they all seem to work somehow. My onChange function looks like function onChange() { alert("in onChange"); } I am just trying to test and make sure it's going to the function, but I get nothing.
Tags (comma-separated)
Save Edits
Cancel