使用chromatable在bootstrap中的使用,首先引用css样式与js
<link rel="stylesheet" href="../../plugins/jquery.chromatable-1.3.0/css/style.css">css
<script src="../../plugins/jQuery/jQuery-2.1.4.min.js"></script>jquery
<script src="../../plugins/jquery.chromatable-1.3.0/jquery.chromatable.js"></script>bootstrap
因为chromatable 的样式中使用的盒子模型是不包含padding与边框的,可是bootstrap 使用的是box-sizing:border-box;全部两者是矛盾的,须要修改chromatable 的样式
只针对于要固定头部的表格table,table td,table th {box-sizing: content-box;}同时采用bootstrap框架写的table的class不能出现table-bordered框架
同时js里面的宽度也要改为100%ip