View Full Version : Table height/width

04-04-2007, 07:56 PM
Is there anyway to find the height and width of a table using php

Scenario: Running a forum and users are able to have there own sig but there is a size limit to their sig, eg 150pixels and id like to make it easier for my staff and have it so when users input their sigs and the table is over 150pixels it'd die

04-04-2007, 08:01 PM
There isn't.

You can get the size of the image used though. And limit it through that. Though if they can have both images and text, then that won't work.


One easy "fix" could be that you put the signature in a div, then apply automatic overflow so that when it gets too big, it turns into a scrollable area. This way it would never reach past 150. Not sure if setting maximum size works great in all popular browsers though.

04-04-2007, 08:03 PM
You could count image height and line rows? But why make it die? I would set this up at insert. Take a little more time to develop that instead of just cutting them off at the end.

04-05-2007, 02:44 AM
im already counting the image pixels etc, i had a look in google for how to count line rows but i could only find it from reading files etc, could you narrow it down a little of me plz

04-05-2007, 04:03 PM
There are just too many variables to be able to do this.

This is what forum moderators are for.