次の解決策を探しています。
JQueryの場合: 同じ名前を持つオブジェクトのすべての親の属性を変更するにはどうすればよいですか?
これが私のコードです:
<div class="roundedOne">
<input type="radio" id="id_single" name = "radStatus" value = "1" />
<label for="id_single"></label>
</div>
<div class="roundedOne">
<input type="radio" id="id_married" name = "radStatus" value = "1" />
<label for="id_single"></label>
</div>
次のようなことをしたい: $("[name='radStatus']").parent().attr("class", "myNewClassName");
ありがとう :)