目前共有3篇帖子。 内容转换:不转换▼
 
点击 回复
239 2
【资料】HTML5复选框的“部分选中”(indeterminate)属性
一派护法 十九级
1楼 发表于:2015-11-22 17:44
Firefox浏览器下的效果:


代码:
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>Untitled Document</title>
<script>
function onload() {
    document.getElementById('test3').indeterminate = true;
}
</script>
<style type="text/css">
body,td,th {
    font-family: Arial;
    font-size: 13px;
}
</style>
</head>

<body onLoad="onload()">
<form>
  <input type="checkbox" checked><br>
  <input type="checkbox" indeterminate id="test"><label for="test">只写一个indeterminate不起作用</label><br>
  <input type="checkbox" id="test2"><br>
  <input type="checkbox" id="test3" /><label for="test3">Checkbox</label><br>
</form>
</body>
</html>

一派护法 十九级
2楼 发表于:2015-11-22 17:45
一派护法 十九级
3楼 发表于:2015-11-22 17:46
IE11浏览器下的效果:

回复帖子

内容:
用户名: 您目前是匿名发表
验证码:
(快捷键:Ctrl+Enter)
 

本帖信息

点击数:239 回复数:2
评论数: ?
作者:巨大八爪鱼
最后回复:巨大八爪鱼
最后回复时间:2015-11-22 17:46
 
©2010-2024 Arslanbar Ver2.0
除非另有声明,本站采用知识共享署名-相同方式共享 3.0 Unported许可协议进行许可。