如何让 text 套用样式表 而 radio 不套用呢。
input
{
border...
}
默认是 所有的 Input 包括文本框 ,Radio,CheckBox 都会掏用此样式 ,能不能 用简单的 办法 让 text 套用样式表 而 radio 不套用呢?
问题点数:20、回复次数:6Top
1 楼fason(咖啡人生)回复于 2003-08-03 17:36:16 得分 10
<style>
input{border:expression(type=='text'?'1px solid red':'')}
</style>
<input><input type=checkbox>
or
.input_text{}
<input class="input_text">
or use HTCTop
2 楼realljx(抵制日货 功在千秋)回复于 2003-08-03 17:51:17 得分 0
你好弓虽Top
3 楼lfh159257(阿廖)回复于 2003-08-03 22:29:34 得分 0
这样也行
<style>
input{
border...
}
</style>
input radio{
border...
}Top
4 楼xushi(不说)回复于 2003-08-04 21:56:33 得分 0
错了,应该是
<style>
input{
border...
}
input radio{
border...
}
</style>
Top
5 楼ronanlin(旭)回复于 2003-08-04 22:35:17 得分 0
分别写样式。。
<input type="text" name="text1" class="textclass">
<input type="radio" name="text1" class="radioclass">
在样式表里写就两个样式就行了。
.textclass
{
}
.radioclass
{
}Top
6 楼liuruhong(蓝色街灯)回复于 2003-08-05 09:57:19 得分 10
fanson得不错,另外阿廖的方法
我看过css2应该是
input[type=radion]{
}
这样子的写法法,大家可以讨论一下Top




