in reply to Re-dimensioning an HTML table with Perl ?

Reading between the lines, it seems likely that what you have is a bunch of elements, not rows and columns of data (in other words, not really a table). using a table to format a collection of boxes is a very HTML 3.2, 1998ish way of doing HTML (and it wasn't the suggested method even back then). It seems somebody noticed that on their monitor, with the browser window whatever size they happen to have it at the moment, using their preferred font size, 7 items can fit in a row. Adjusting layout to fit different screens, different text sizes, etc is precisely what a web browser is for! It very likely shouldn't be a table with some predefined number of rows at all. Rather, it should be a sequence of boxes. Let the browser do its job and decide how many boxes fit in each row, on a particular display.

To make each box the same width so they line up nicely you'd use some CSS like this:

.gallery{ display:block; } .thumbnail{ display:inline-block; border:1px solid black; float:left; height:200px; width:100px; margin-left: 1em; }