Advanced Web Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 
Go Back   Dev Articles Community ForumsWeb DesignAdvanced Web Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
  #1  
Old January 9th, 2005, 09:15 AM
Spongy's Avatar
Spongy Spongy is offline
Alternately High
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Location: Hilversum, Netherlands
Posts: 223 Spongy User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 13 h 56 m 41 sec
Reputation Power: 6
Send a message via MSN to Spongy
Unhappy Positioning difference IE vs FF

Help!

This isn't supposed to happen, but it did. I cannot find the problem.

Please take a look at the screenshots and you will see the problem immediately.
This is my XHTML:
Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Fetish-Fantastique.nl</title>
<meta http-equiv="Content-Type"
content="text/html; charset=iso-8859-1" />
<meta name="Robots" content="NOINDEX" />
<meta http-equiv="PRAGMA" content="NO-CACHE" />
<link rel="stylesheet" type="text/css" href="2c-hd-ft-fixed-layout.css" />
<link rel="stylesheet" type="text/css" href="2c-hd-ft-fixed-presentation.css" />
</head>
<body>
<div id="outer">
<div id="hdr"></div>
<div id="bar"><p>The Hot and Horny Party of the North</p></div>
<div id="bodyblock" align="right">
<div id="l-col">
<a href="#">Home</a><br />
<a href="#">Pictures</a><br />
<a href="#">Route</a><br />
<a href="#">Contact</a><br />
<a href="#">Links</a><br />
</div>
<div id="cont">
<h3>Een Kinky Fetish party Fantastique!!</h3>
<p style="font-weight:bold;">Waarom een fkinky fetish party in Noord nederland? 
Omdat er erg veel mensen zijn met een heerlijke fetish en daar met andere mensen heerlijke feesten wil meemaken. 
Allereerst, wat is een fetish? Even een paar qoutes van verschillende bronnen:</p>
<img src="images/drescode_4.jpg" alt="" title="" />

Het verschil tussen fetish en mania 
Met fetish bedoelen we de behoefte aan een voorwerp, kleding of lichaamsdeel, dat iemand nodig heeft bij zijn/haar seks. Zonder aandacht te besteden aan dat voorwerp is de seks niet compleet (en kan diegene ook niet écht opgewonden worden).
Met mania bedoelen we sexuele neigingen die wat extreem zijn, of waarbij je bepaalde on-sexuele dingen betrekt, maar alleen als uitbreiding van je sexleven. Het is dus geen noodzaak.

</div>
</div>
<div id="ftr" align="center">Copyright ©2005 Fetish-Fantastique.nl</div>
</div>

</body>
</html>


And this is the css:
Code:
body {
 margin:20px;
 background-color:#666666;
 text-align:center;
 padding:0;
 background-image:url(logo2.gif);
 background-position:left top;
 background-repeat:no-repeat;
 background-attachment:fixed;
 }

#outer {
 text-align:left;
 border:1px solid #000000;
 width:650px;
 margin:auto;
 }

#hdr {
 height:60px;
 background:#000000;
 background-image:url(logo.png);
 color: #333333;
 }

#bar {
 height:25px;
 background:#000000;
 border:solid #000000;	
 border-width:1px 0 1px 0;
 padding-left: 5px;
 }

#bodyblock {
 position:relative;
 background: #000000;
 width:650px;
 padding:0;
 }

#l-col {
 float:left;
 background:#FFFFFF;
 width:145px;
 text-align:left;
 padding-left: 10px;
 }

#cont {
 width:495px;
 background:#292929;
 border:solid #000000;	
 border-width:0 0 0 1px;
 text-align:left;
 }

#ftr {
 height:25px;
 background:#c0c0c0;
 color: #333333;
 border:solid black;
 border-width:1px 0 0 0;
 margin:0;
 }


Please help cause I'm getting desperate!

Thanks in advance,

Spongy
Attached Images
File Type: gif screenshot_FF.gif (43.6 KB, 835 views)
File Type: gif screenshot_IE.gif (43.2 KB, 763 views)
__________________
Work to live, don't live to work

Last edited by Spongy : January 9th, 2005 at 10:42 AM.

Reply With Quote
  #2  
Old January 10th, 2005, 08:17 AM
pocketsized pocketsized is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: May 2004
Location: Brunei
Posts: 26 pocketsized User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
The problem is that there isn't enough horizontal space for the div #cont.

Code:
  #outer {
    text-align:left;
    border:1px solid #000000;
  width:650px;
    margin:auto;
    }
   
  #bodyblock {
    position:relative;
    background: #000000;
  width:650px;
    padding:0;
    }
   


You've allowed a max horizontal width of 650px.

Code:
   #l-col {
    float:left;
    background:#FFFFFF;
  width:145px;
    text-align:left;
    padding-left: 10px;
    }
   


Total width of #l-col = 145 + 10 = 155px. There is only 495px left for #cont

Code:
   #cont {
  width:495px;
    background:#292929;
    border:solid #000000;	
  border-width:0 0 0 1px;
    text-align:left;
    }
   


Total width of #cont = 495 + 1 = 496px. You are 1-pixels to many.

I commented out the border declarations but strangely it still didn't display properly in IE until I added a float: left to #cont.

Code:
    #cont {
   float: left;
   width:495px;
     background:#292929;
   /*border:solid #000000;	
   border-width:0 0 0 1px;*/
     text-align:left;
     }
   


If you still want your borders, then remove the horizontal width required from the the width declaration (495px)

Reply With Quote
  #3  
Old January 10th, 2005, 08:40 AM
MadCowDzz's Avatar
MadCowDzz MadCowDzz is offline
I'm Internet Famous
Dev Articles Frequenter (2500 - 2999 posts)
 
Join Date: Jan 2003
Location: Toronto, Canada
Posts: 2,890 MadCowDzz User rank is Lance Corporal (50 - 100 Reputation Level)MadCowDzz User rank is Lance Corporal (50 - 100 Reputation Level)MadCowDzz User rank is Lance Corporal (50 - 100 Reputation Level) 
Time spent in forums: 1 Week 16 h 14 m 9 sec
Reputation Power: 9
To supplement pocketsized's post, what happens if you reduce your width property to 494px?
[or even a couple more pixel reduction if possible]

Reply With Quote
  #4  
Old January 10th, 2005, 09:44 AM
Spongy's Avatar
Spongy Spongy is offline
Alternately High
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Location: Hilversum, Netherlands
Posts: 223 Spongy User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 13 h 56 m 41 sec
Reputation Power: 6
Send a message via MSN to Spongy
First of all, thanks for the replies! This really got me thinking about it. I tried MadCowDzz solution first (for the simplicity of course). Just reducing it with a pixel didn't work. Until I floated the whole thing to the left, like pocketsized suggestion. I got rid of the borders, since I didn't need them anyway, and now the page looks superb in IE but.... in FF the outerdiv wasn't continued around the #cont-div because of the float:left; A clear:both; on the footer did the job. After I'd set the background-color for the #outer-div, the page really looked good in both browsers.

For people who are interested, this is the code as I have it right now:
Code:
body {
 margin:20px;
 background-color:#666666;
 text-align:center;
 padding:0;
 background-image:url(logo2.gif);
 background-position:left top;
 background-repeat:no-repeat;
 background-attachment:fixed;
 }

#outer {
 text-align:left;
 border:1px solid #000000;
 width:650px;
 margin:auto;
 background-color:#000000;
 }

#hdr {
 height:60px;
 background:#000000;
 background-image:url(logo.png);
 color: #333333;
 }

#bar {
 height:25px;
 background:#000000;
 border:solid #000000;	
 border-width:1px 0 1px 0;
 padding-left: 5px;
 }

#bodyblock {
 position:relative;
 background: #000000;
 width:650px;
 padding:0;
 }

#l-col {
 float:left;
 background:#000000;
 width:145px;
 text-align:left;
 padding-left: 10px;
 }

#cont {
 width:495px;
 background:#292929;
 /*border:solid #000000;	
 border-width:0 0 0 1px;*/
 text-align:left;
 float: left;
 }

#ftr {
 height:25px;
 background:#c0c0c0;
 color: #333333;
 border:solid black;
 border-width:1px 0 0 0;
 margin:0;
 clear:both;
 }


Thanks again, see you next time.

Spongy

Last edited by Spongy : January 10th, 2005 at 09:55 AM.

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsWeb DesignAdvanced Web Development > Positioning difference IE vs FF


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump




 Free IT White Papers!
 
How to Present Effectively Online
This white paper offers practical and actionable advice on the key steps that any presenter should consider as they plan and execute a Webinar or online meeting.

Request Your Free Technology Downloads!
 
Open Source Security Myths
Open Source Software (OSS) is computer software whose source code is available to the general public with relaxed or non-existent intellectual property restrictions (or arrangement such as the public domain), and is usually developed with the input of many contributors.

Request Your Free Technology Downloads!
 
Power and Cooling Capacity Management for Data Centers
This paper describes the principles for achieving power and cooling capacity management.

Request Your Free Technology Downloads!
 
Scalable, Fault-Tolerant NAS for Oracle - The Next Generation
For several years NAS has been evolving as a storage alternative for Oracle databases, and for good reason: NAS is quite often the simplest, most cost-effective storage approach for Oracle. Learn about the benefits that HP's approach to scalable NAS brings to Oracle environments in this comprehensive white paper.

Request Your Free Technology Downloads!
 
Understanding Web Application Security Challenges
This white paper discusses many common threats and preventive measures for Web application security, and explains what you can do to help protect your organization.

Request Your Free Technology Downloads!
 

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 




© 2003-2009 by Developer Shed. All rights reserved. DS Cluster 6 Hosted by Hostway
For more Enterprise Application Development news, visit eWeek