วันอาทิตย์ที่ 7 มีนาคม พ.ศ. 2564

table fixed thead on top with css

 table {

  text-align: left;
  position: relative;
  border-collapse: collapse; 
}
th {
  background: white;
  position: sticky;
  top: 0; /* Don't forget this, required for the stickiness */
  box-shadow: 0 2px 2px -1px rgba(0, 0, 0, 0.4);
}

ไม่มีความคิดเห็น:

แสดงความคิดเห็น