Tablerow formatting messed up by display:block

user9333933 Source

I did see this. But using display block is what's messing it up.

I'm wondering how I can make table rows appear and disappear, without messing up the formatting.

Currently this is what I'm using:

<%String fieldsDisplay = (type.equals("Add")) ? "display:block" : "display:none";%>

I'm using this as a style in my table row. But when I add this style, the formatting gets messed up. There are currently three columns and the spacing between them just gets removed



answered 6 months ago Yvo Linssen #1

Make use of the table-row display property instead.

<%String fieldsDisplay = (type.equals("Add")) ? "display:table-row" : "display:none";%>

comments powered by Disqus