Skip to content

Instantly share code, notes, and snippets.

@kdssoftware
Last active April 3, 2020 11:28
Show Gist options
  • Save kdssoftware/f86e604a05b0b73441044cafb6217f6c to your computer and use it in GitHub Desktop.
Save kdssoftware/f86e604a05b0b73441044cafb6217f6c to your computer and use it in GitHub Desktop.
EBCS fixed to top
.headingtable {
top: 79px !important; /*Offset van bovenkant*/
background-color: #c0c0c0 !important; /*Background kleur override, voor black theme*/
}
.headingtable tr td{
border: 0; /*Chrome geeft automatisch border, verwijderd borders*/
}
var childeren = $('table#dataScherm_grd tbody tr.myheader')[0].cells;
let thead = '<thead class="myheader">';
for(var c of childeren){
thead+= "<td style=\"width:"+c.clientWidth+"px !important;"+
"height:"+c.clientHeight+"px !important;"+
"left:"+c.clientLeft+"px !important;"+
"top:"+c.clientTop+"px !important;\""+
((c.className)?"class=\""+c.className+"\"":"")+">"+
c.innerText+
"</td>";
}
thead += "</thead>";
$('table#dataScherm_grd').prepend(thead);
$('table#dataScherm_grd tbody tr.myheader').remove();
$("table#dataScherm_grd thead.myheader").addClass("scrollfixed");
$("table#dataScherm_grd thead.myheader").addClass("headingtable");
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment