Welcome to WebmasterWorld Guest from 54.163.35.238

Forum Moderators: incrediBILL

Message Too Old, No Replies

Firefox DIV Issues

Firefox DIV Issues

     

Skim_Milk

6:28 pm on Aug 11, 2004 (gmt 0)

10+ Year Member



For some reason, when I create a new page and insert a div tag, firefox automatically puts space between that div and the rest of the page. The DIV has images in it and I tried using display block for my IMG tags, but it did not resolve the issue, anythoughts?

Thanks,
Nick

Here is some code to munch on. Am I using the right doctype?


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body>
<div>
<h2>Some Heading</h2>
<p>Some text...</p>
<h2>Color-Coded Ledger Look-Up</h2>
<p><a href="images/ledgerLookupBig.jpg" target="_blank"><img src="images/ledgerLookup.jpg" width="265" height="173" border="0" align="right" class="content" alt="Alt Test"></a>DSome text...</p>
<h2>Some heading</h2>
<p>Some text...</p>
<ul>
<li>List...</li>
<li>List...</li>
</ul>
<h2>Some heading</h2>
<p>Some text...</p>
<h2>Some heading</h2>
<p>Some text...</p>
</div>
</body>
</html>

[edited by: BlobFisk at 7:43 pm (utc) on Aug. 11, 2004]
[edit reason] Removed specifics [/edit]

RFranzen

8:20 pm on Aug 11, 2004 (gmt 0)

10+ Year Member



Nick,

I don't see any problem. On my Windows 2000 machine, Firefox 0.9.3 and IE 6.0 are rendering the HTML code in the same manner.

-- Rich

Skim_Milk

8:51 pm on Aug 11, 2004 (gmt 0)

10+ Year Member



Hmmmm, interesting. Perhaps it is my machine. Thanks for the help.

Nick

encyclo

9:07 pm on Aug 11, 2004 (gmt 0)

WebmasterWorld Senior Member encyclo is a WebmasterWorld Top Contributor of All Time 10+ Year Member



Am I using the right doctype?

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/strict.dtd">

It might not be anything to do with your problem, but you are definitely not using the right doctype. The above is a mix between Transitional and Strict.

The correct doctypes are:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">

For HTML 4.01 Strict, and:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

For HTML 4.01 Transitional.

If you're not sure which one you are supposed to use, then choose the second one!

 

Featured Threads

Hot Threads This Week

Hot Threads This Month