What is the code to initialize a query text box in Javascript? All my js code is in a backbone file. I cannot find the proper code to initialize a text box with the following HTML:
<input type="text" id="searchquery" name="name" value="Alien"/>
…anybody know how to do this?
A “text” input tag creates a “Text” object in the HTML DOM. The value of the text for that object is the “value” property.
Manipulate in the usual JavaScript way. For more info see —
http://www.w3schools.com/jsref/dom_obj_text.asp
Enjoy!