Hi
I saw this solution about 'hiding all input elements within a form'
HTML:
<body>
<form name='demo_form'>
First name: <input type="text" name="fname"><br>
Last name: <input type="text" name="lname"><br>
<input type="submit" value="Submit">
</form>
</body>
Solution as i wrote:
$(document).ready(function(){
$
("input").hide();
});
The above code worked, however the given solution was:
$
( demo_form.elements ).hide();
I would like to know: Isn't 'elements' a generic selector?
isn't it more specific to use 'input'?
Also, how do you select the form by name?
Thanks a lot for helping me!
Jayashree