我正在尝试添加用户从收音机中检查的值,并将其显示在具有相应标题的类“用户集”的跨度中。问题是当它显示该值时,它会显示在具有“用户集”的跨度类的所有标题上。
这是一个例子:http: //jsfiddle.net/fPWY3/
<div class='accordion'>
<div class='heading'>
<img src=''> heading <span class='f12'>info</span> <span class='user-set'></span>
</div>
<div class='items'>
<input type='radio' class='next' name='theName' id='theName1'><label for='theName1'>thisIsMyValue 1</label>
</div>
<div class='items'>
<input type='radio' class='next' name='theName' id='theName2'><label for='theName2'>thisIsMyValue 2</label>
</div>
<div class='heading'>
<img src=''> heading 2<span class='f12'>info</span> <span class='user-set'></span>
</div>
<div class='items'>
<input type='radio' class='next' name='theName2' id='theName3'><label for='theName3'>thisIsMyValue 3</label>
</div>
<div class='items'>
<input type='radio' class='next' name='theName2' id='theName4'><label for='theName4'>thisIsMyValue 4</label>
</div>
</div>
如果我单击“thisIsMyValue 3”,我该怎么做,该值将显示在跨度上,仅标题 2 中的用户设置类?