JavaScript and client side scripting.
Moderator: General Moderators
Luke
The Ninja Space Mod
Posts: 6424 Joined: Fri Aug 05, 2005 1:53 pm
Location: Paradise, CA
Post
by Luke » Tue Sep 12, 2006 6:46 pm
that would be a reference to the value of the content element on the first form on the page.
forms[0] is the first form forms[1] is the second, and so on. (it's an array) content would be either the name or id of an element in the form and value is obvious.
Shendemiar
Forum Contributor
Posts: 404 Joined: Thu Jan 08, 2004 8:28 am
Post
by Shendemiar » Tue Sep 12, 2006 6:50 pm
The Ninja Space Goat wrote: ...content would be either the name or id of an element...
Thanks...
I assumed its somekind of property or a method... reference to somemething... ;D
Luke
The Ninja Space Mod
Posts: 6424 Joined: Fri Aug 05, 2005 1:53 pm
Location: Paradise, CA
Post
by Luke » Tue Sep 12, 2006 6:56 pm
In the following html file, that line of javascript would return "Foobar"
Code: Select all
<html>
<body>
<form>
<input type="text" name="header">
<input type="text" name="content" value="Foobar">
</form>
<form>
<input type="text" name="content" value="This is not the right content element">
</form>
</body>
</html>
gkwhitworth
Forum Commoner
Posts: 85 Joined: Tue Sep 05, 2006 8:28 pm
Location: Wasilla, Alaska
Post
by gkwhitworth » Tue Sep 12, 2006 7:15 pm
awe man, I want an award!
oh...nice horns.
Luke
The Ninja Space Mod
Posts: 6424 Joined: Fri Aug 05, 2005 1:53 pm
Location: Paradise, CA
Post
by Luke » Tue Sep 12, 2006 7:51 pm
make one up... I did.