G
Griff
I've a (classic) ASP web page that has several tables on it that have
identical columns (headings).
When these tables are displayed they of course have different widths, based
upon the amount of text within each column.
I have been asked to make all tables have identical column widths.
What I thought I would do would be to have some sort of column-width counter
that counted the maximum number of characters in column A in all tables, and
another for column B in all tables. From this I would have to come up with
some algorithm (not yet done) to turn the number of characters into a column
width (based upon font family and font size chosen). This value would then
be put into a programmatically generated style sheet. However, a quick
prototype shows that the style sheet appears to be ignored if it's at the
end of the document (even if in a <head/> tag) and the aforementioned
algorithm would appear to be rather complicated....
So - I'm after a new approach. I don't want to make it into one big table
because I've sections of information that appear between the tables.
Could I do something in JavaScript on the Client's machine?
All thoughts most welcome.
Thanks
Griff
identical columns (headings).
When these tables are displayed they of course have different widths, based
upon the amount of text within each column.
I have been asked to make all tables have identical column widths.
What I thought I would do would be to have some sort of column-width counter
that counted the maximum number of characters in column A in all tables, and
another for column B in all tables. From this I would have to come up with
some algorithm (not yet done) to turn the number of characters into a column
width (based upon font family and font size chosen). This value would then
be put into a programmatically generated style sheet. However, a quick
prototype shows that the style sheet appears to be ignored if it's at the
end of the document (even if in a <head/> tag) and the aforementioned
algorithm would appear to be rather complicated....
So - I'm after a new approach. I don't want to make it into one big table
because I've sections of information that appear between the tables.
Could I do something in JavaScript on the Client's machine?
All thoughts most welcome.
Thanks
Griff