Ho il seguente codice HTML:

<form id="registration" action="/cgi-bin/registration.cgi" method="POST" onsubmit="return control()">
<fieldset>
<legend>Legend 1</legend>
<label>......</label> <input ..../>

<label>......</label> <input ....onclick="return orgreg()"/>

</fieldset>
<fieldset>
<legend>Legend 2</legend>
<label>......</label> <input ..../>

<label>......</label> <input ..../>

<label>......</label> <input ..../>

<label>......</label> <input ..../>

<label>......</label> <input ..../>

</fieldset>
........
........
e il seguente codice javascript:
function orgreg() {

if (document.getElementById) {
alert(document.getElementById("registration").firs tChild);
}

}
L'output di questa finestra di alert è:[Object Text]
Ora il primo figlio si riferisce al primo tag fieldset, giusto? ...e non al tag legend?
[/QUOTE]