Closed
Bug 132520
Opened 23 years ago
Closed 23 years ago
Table TD height differs using different DOCTYPE
Categories
(Core :: Layout: Tables, defect)
Tracking
()
People
(Reporter: wolfandreas, Assigned: karnaze)
Details
Attachments
(3 files)
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (Windows; U; Win98; en-US; rv:0.9.9) Gecko/20020311
BuildID: 2002031104
Using
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
the height of a <td> is different than using
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
Reproducible: Always
Steps to Reproduce:
1. Use Code-Example
Actual Results: The table row got rather big with
"http://www.w3.org/TR/html4/loose.dtd".
Expected Results: Keep the same height of <td>
I used the following code, with the two Doctypes mentioned above
Case 1:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
</head>
<body>
<table border="0" cellspacing="0" cellpadding="0" width="400">
<tr>
<td bgcolor="#000000" height="2"><img src="images/trasp.gif" alt="" width="80"
height="2"> </td>
</tr>
</table>
<br>
<table border="0" cellspacing="0" cellpadding="0" width="400">
<tr>
<td bgcolor="#000000" height="2"><img src="images/trasp.gif" alt="" width="80"
height="2"></td>
</tr>
</table>
</body>
</html>
Case 2:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
</head>
<body>
<table border="0" cellspacing="0" cellpadding="0" width="400">
<tr>
<td bgcolor="#000000" height="2"><img src="images/trasp.gif" alt="" width="80"
height="2"> </td>
</tr>
</table>
<br>
<table border="0" cellspacing="0" cellpadding="0" width="400">
<tr>
<td bgcolor="#000000" height="2"><img src="images/trasp.gif" alt="" width="80"
height="2"></td>
</tr>
</table>
</body>
</html>
where trasp.gif is a transparent 1x1 pixel gif
I assume that the different height of the rows without the loose.dtd (there is a
whitespace after img-tag in first table) was already reported as invalid bug ?!
The Testcase does not work properly. The image is not loaded.
So Testcase 2 shows 2 perfect small lines.
Can somebody help me with this please ?
I don't know how to refer to the image correctly.
Thanks.
Comment 5•23 years ago
|
||
Read this article:
http://developer.netscape.com/evangelism/docs/articles/img-table/
to solve your problem.
*** This bug has been marked as a duplicate of 22274 ***
Status: UNCONFIRMED → RESOLVED
Closed: 23 years ago
Resolution: --- → DUPLICATE
You need to log in
before you can comment on or make changes to this bug.
Description
•