单选按钮在ie和chrome中消失

dha*_*val 5 html css internet-explorer google-chrome radio-button

以下是样式表

 select,input ,td a {border:1px solid green; width:25%;height:25px;font-size:20px;margin-  left:.1em;}
input.myradio {border:none;width:0%;height:0%;font-size:0%;}
Run Code Online (Sandbox Code Playgroud)

以下是html

<td><input class="myradio"  type="radio" name="poolstatus" value="Add">Add</input><td>
Run Code Online (Sandbox Code Playgroud)

它在Firefox中是完美的,但Chrome和IE没有显示单选按钮?为什么这样?

ibl*_*ish 7

这是因为你告诉单选按钮是0%高 - 这是0px - 这是不存在的.

您可以通过告诉高度和宽度为"auto"来重置它们(这将重置它们)(除非样式表中的其他地方更具体的规则)

input.myradio {
  border:none;
  width:auto;
  height:auto;
}
Run Code Online (Sandbox Code Playgroud)