在复选框<form>
<input type="checkbox" name="bike">
I have a bike
<br>
<input type="checkbox" name="car">
I have a car
</form>这段代码中,name的名字如果是一样会不会影响到网页?另外,这里也没有单选框中value的属性。 在单选框<form>
<input type="radio" name="sex" value="male"> Male
<input type="radio" name="sex" value="female"> Female
</form> 在单选框中,我试了把name的值改为不同名字,这样我就可以同时选择两个了。是怎么回事?难道单选框中name的值必须是相同名字吗,为什么?