Menu Close

How to add horizontal scrollbar on top and bottom of table with CSS?

To add horizontal scrollbar on top and bottom of table with CSS, we set the transform property.

For instance, we write

.parent {
  transform: rotateX(180deg);
  overflow-x: auto;
}

.child {
  transform: rotateX(180deg);
}

to rotate the element with class parent 180 degrees with transform: rotateX(180deg);.

And we rotate the element with class child in the element with class parent 180 degrees with transform: rotateX(180deg);.

Posted in CSS