Problem with XHTML in Mozilla

Adam (archive)

Usenet Archive
Joined
Feb 9, 2000
Messages
262
Reaction score
0
hi!

the code below without the doctype definition works fine in both IE and Mozilla. if I add the doctype line code works ok in IE but in Mozilla a black boarder apperas around the picture and I can't remove it. Do you have any ideas how to correct it?

regards
adam

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<head>
<title>test title</title>
</head>
<body>

<table "width="100%" cellspacing="0" cellpadding="0" border="1"> <tr> <td><img src="ie.gif" width="300" height="40" /></td> </tr> </table>

</body>
</html>
 

Els

Usenet Archive
Joined
Jul 31, 2003
Messages
2,286
Reaction score
0
Adam said:
hi!

the code below without the doctype definition works fine in both IE and Mozilla. if I add the doctype line code works ok in IE but in Mozilla a black boarder apperas around the picture and I can't remove it. Do you have any ideas how to correct it?

Have you tried validating your code?
 

Spartanicus

Usenet Archive
Joined
Oct 22, 2003
Messages
1,110
Reaction score
0
Adam said:
the code below without the doctype definition works fine in both IE and Mozilla. if I add the doctype line code works ok in IE but in Mozilla a black boarder apperas around the picture and I can't remove it.

Mozilla is switched into standard compliant mode with the doctype.
Do you have any ideas how to correct it?

[Assuming that the extraneous " is a typo]

img{vertical-align:text-bottom}

Or several other values for the vertical-align property get rid of the space in Mozilla.
 

Rincewind

Usenet Archive
Joined
Jul 25, 2005
Messages
74
Reaction score
0
hi!

the code below without the doctype definition works fine in both IE and Mozilla. if I add the doctype line code works ok in IE but in Mozilla a black boarder apperas around the picture and I can't remove it. Do you have any ideas how to correct it?

regards
adam

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<head>
<title>test title</title>
</head>
<body>

<table "width="100%" cellspacing="0" cellpadding="0" border="1"> <tr> <td><img src="ie.gif" width="300" height="40" /></td> </tr> </table>

</body>
</html>

I don't see a line around the picture on IE or FF but there is one around the Table beacause you've specified one.
 

jlbdoc95

Usenet Archive
Joined
Jul 27, 2005
Messages
6
Reaction score
0
Adam said:
hi!

the code below without the doctype definition works fine in both IE and Mozilla. if I add the doctype line code works ok in IE but in Mozilla a black boarder apperas around the picture and I can't remove it. Do you have any ideas how to correct it?

First, as already mentioned, this does not validate, missing opening <HTML> tag, extra quote before width in the <table> tag and missing the alt attribute. The border however is coming from the table border, not the actual image (unless of course the actual image has a border as part of the ..gif).

Doc95
 

Noodles Jefferson

Usenet Archive
Joined
Jun 29, 2005
Messages
64
Reaction score
0
Adam said:
hi!

the code below without the doctype definition works fine in both IE and Mozilla. if I add the doctype line code works ok in IE but in Mozilla a black boarder apperas around the picture and I can't remove it. Do you have any ideas how to correct it?

regards
adam

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<head>
<title>test title</title>
</head>

<style>
img {border:none}
<body>

<table "width="100%" cellspacing="0" cellpadding="0" border="1"> <tr> <td><img src="ie.gif" width="300" height="40" /></td> </tr> </table>

</body>
</html>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
548,049
Messages
3,104,243
Members
248,133
Latest member
DujonT

Latest Threads

Top