如何使用标签?这样你得到按钮的功能,但标签的可见性。在Firefox和Chrome中测试。表单提交的更新示例。
>没有JavaScript涉及单元格区域的可点击性
>在容器上没有固定高度的情况下工作
>当不同的单元格的高度大于按钮的高度时工作
>适用于多个纽扣电池
HTML:
1
2
3
4
5
Extended cell
Extended cell
Button 1
Button 2
CSS:
.container {
margin: 10px;
border: 5px solid blue;
display: table;
table-layout: fixed;
width: 300px;
}
.item {
border: 3px solid red;
display: table-cell;
}
.item button {
background-color: transparent;
position: absolute;
left: -1000px;
height: 1px;
width: 1px;
overflow: hidden;
}