Suppose I have the following bit of code:
<p>
<label>
<input name="milk" type="checkbox">
<span>Milk</span>
</label>
</p>
How can I use javascript to obtain the text between the span
tags? The result should be Milk
if logged onto the console. Thank you!
Aucun commentaire:
Enregistrer un commentaire