Jump to content

table TD height - FIXED ?


lvertel

Recommended Posts

hello

 

simple question but yet impossible for me to find a solution :

 

i have a php script, that shows me data in TABLE , so in the end, i have let's say, 10 rows in 10 tables...

 

however, the data(text) inside of each text is of different size, and according to that, my TD is changing it's height.

 

I did put the td height = 100, but the text that php generates, makes the TD higher.

 

How could i make the TD height FIXED, no matter what amount of content there is in the TD??

Link to comment
Share on other sites

You'll need to use CSS.

<td style="height:100px;overflow:hidden;">

The overflow:hidden attribute will hide anything larger than the element size.

 

Hmm, i have tried it but unfortunately it didn't work

 

Any other solution ?

Link to comment
Share on other sites

Well, I've never tried the overflow on a <td> element, so maybe that's the problem. OK, try this: put a <div> inside the <td> and add that style to the div, and put your content into the div.

 

great, it is working ... but only on IE

 

FIREFOX and CHROME are still the problem. any other solution ?

 

here is the example :

 

http://eventy.ch/events.php?category=all

 

u can see that CINEMA RIALTO LOCARNO is more then the 55px i've set up for height

 

however, in IE it is showin good!

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.