How do I make a table scrollable

You need to declare a height first, else your table will expand to the according width of its content. table{ overflow-y:scroll; height:100px; display:block; } EDIT: after clarifying your problem I edited the fiddle: check out this Example or that way. It’s rather hacky and not guaranteed to work crossbrowser but might work for your case.

Why does this behave the way it does with max-width: 0?

Note: It’s not just max-width:0, it’s any width less than the text content’s width. The mixture of display: table-cell, max-width, and width:100% make an interesting situation that the specifications don’t explicitly cover. However, by making some observations and thinking, we can understand why we have the same behavior across all major browsers. max-width:0 tries to … Read more

CSS specific table

Just apply the .beta class selector to the entire table and change your CSS code to apply a rule only to td decedents of .beta like this: <table class=”beta”> <tr> <td>…</td> <td>…</td> </tr> </table> .beta td { border-style:solid; border-top:thick double #ff0000; } If you need to apply the rule to multiple elements within .beta simply … Read more

Box Shadow on table row not appearing on certain browsers

Use transform scale(1,1) property with box-shadow it will solve the problem. tr:hover { transform: scale(1); -webkit-transform: scale(1); -moz-transform: scale(1); box-shadow: 0px 0px 5px rgba(0,0,0,0.3); -webkit-box-shadow: 0px 0px 5px rgba(0,0,0,0.3); -moz-box-shadow: 0px 0px 5px rgba(0,0,0,0.3); } Fiddle: https://jsfiddle.net/ampicx/5p91xr48/ Thanks!!

Setting a max height on a table

NOTE this answer is now incorrect. I may get back to it at a later time. As others have pointed out, you can’t set the height of a table unless you set its display to block, but then you get a scrolling header. So what you’re looking for is to set the height and display:block … Read more