Board index   FAQ   Search  
Register  Login
Board index php forum :: HTML HTML Basics

Minimum table height ?

Discussing Html . Code , Software , other

Moderators: macek, egami, gesf

Minimum table height ?

Postby WoozyDuck » Fri Oct 22, 2004 7:03 am

Hiya all

Ive tried to set the height of a table to 5 pixels or something
but its not possible! the minimum size of a table's height is
something around 20 pixels!
I even try to use CSS for this , but that doesnt work as well!
how can I set a table's height to less than 20 pixels ?

Thanx
User avatar
WoozyDuck
New php-forum User
New php-forum User
 
Posts: 191
Joined: Wed May 05, 2004 10:14 am

Postby swirlee » Fri Oct 22, 2004 7:08 am

There's no "minimum height" for a table. If you have text (including a space or   ) in the table, the table will be at least as large as the text. In CSS you can get around this by using overflow: hidden.
User avatar
swirlee
Moderator
Moderator
 
Posts: 2272
Joined: Sat Jul 05, 2003 1:18 pm
Location: A bunk in the back

Postby WoozyDuck » Fri Oct 22, 2004 7:17 am

so what I understand from your answer is we cant make
a fix height table which doesnt include any text inside of it! ... strange!
well this is the minimum size that Ihave found for a table:

Code: Select all
 <td width="100%"><span style="font-size: 1">&nbsp;</span></td>


well the story is I have table , and I have one picture which has 10 pixelx height! so whenever I put this piccy inside of the table , there is an empty space remain in bottom of the table which is about 10 pixels!
I just wanted to fit the table to my picture ,!

but I think I got the idea from your answer so I can sort it out.
cheers mate
User avatar
WoozyDuck
New php-forum User
New php-forum User
 
Posts: 191
Joined: Wed May 05, 2004 10:14 am

Postby swirlee » Fri Oct 22, 2004 7:51 am

WoozyDuck wrote:so what I understand from your answer is we cant make
a fix height table which doesnt include any text inside of it!


No, I said that you can't do so if it does include any text inside of it, and &nbsp; counts as text.

Some versions of IE handle whitespace badly. If you have a 10px image in a table cell and you want to make sure the cell is exactly 10px, you have to make sure there's no whitespace (which includes spaces, tabs, and newlines) between the <img> tag and the HTML before or after it.
User avatar
swirlee
Moderator
Moderator
 
Posts: 2272
Joined: Sat Jul 05, 2003 1:18 pm
Location: A bunk in the back

Postby WoozyDuck » Sat Oct 23, 2004 3:56 am

Ok mate
I got it
Thanx for the help :)
User avatar
WoozyDuck
New php-forum User
New php-forum User
 
Posts: 191
Joined: Wed May 05, 2004 10:14 am


Return to HTML Basics

Who is online

Users browsing this forum: TurnitinBot [Bot] and 1 guest

Sponsored by Sitebuilder Web hosting and Traduzioni Italiano Rumeno and antispam for cPanel.