Re: cloning nodes vs. creating new() ones

Petr Stehlik <[email protected]> Tue, 16 Sep 2003 10:44:02 +0200
Newsgroups gmane.comp.java.enhydra.xmlc
Message-ID <[email protected]>
V Út, 16. 09. 2003 v 10:20, Matthew Hixson píše:
> I still can't seem to get away from using getFirstChild() to get ahold 
> of the text inside the <option> tag, like so:
> 
> <option id="teacherName">Mrs. Wormwood</option>
> 
> How do you access the "Mrs. Wormwood" part?

Use the span tag.

<option id="teacherOption"><span id="teacherName">Mrs.
Wormwood</span></option>

Then it will be as easy as page.setTextTeacherName("new name");

Petr