height: 100% Browser issues - okay in IE not in FF or Opera

This is a discussion on "height: 100% Browser issues - okay in IE not in FF or Opera" within the Web Page Design section. This forum, and the thread "height: 100% Browser issues - okay in IE not in FF or Opera are both part of the Design Your Website category.



Go Back   Webforumz.com > Main Forums > Design Your Website > Web Page Design

Notices


Reply
 
LinkBack Thread Tools
  #1 (permalink)  
Old Aug 28th, 2007, 14:21
New Member
Join Date: Aug 2007
Location: u.k.
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Red face height: 100% Browser issues - okay in IE not in FF or Opera

I have a problem with how the different browsers display my page. IE6 is displaying it how i want with the background colour of white showing all the while i have content and then adding the padding/margin sizes on top.
However in Firefox and Opera the white background only seems to show for a very small section of the page.
All of my content is held in a container div as follows:

Code: Select all
#container {
width:955px;
align: center;
text-align: left;
margin-right: auto;
margin-left: auto;
margin-top:20px;
}
Then I have another div nesting in this which displays my right hand content:

Code: Select all
#right_content {
border-left: 1px solid #00000000;
margin-left: 2px ;
margin-right:2px ;
background: #ffffff;
height: 100%;
}
And finally i have another div nested inside that which contains my gallery

Code: Select all
.gallery{
float: left;
margin-bottom: 2em;
 
}
dl.gallery
{
border: 1px solid #fff;
background-color: #B2DBFB;
width: 252px;
max-height: 25em;
text-align: center;
padding: 10px;
align: left;
margin-right: 1em;
margin-left: 1em;
margin-bottom: 4em;
}
Can anyone tell me where i'm going wrong? The only way I seem to be able to get Firefox and Opera to display my white background to the bottom of the document is by specifying a pixel height i.e.:
height: 1200px;
which obviously i do not want to do, as each page on my website will have a different height size dependent on the amount of contained contained in it.
With many thanks for any light on this matter - i've been tearing my hair out on this one for a couple fo days!!

Last edited by Daniel; Oct 27th, 2007 at 09:01. Reason: Pleasse use [code] tags when posting code.
Reply With Quote

  #2 (permalink)  
Old Oct 27th, 2007, 04:22
Highly Reputable Member
Join Date: Sep 2007
Age: 15
Posts: 717
Blog Entries: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Re: height: 100% Browser issues - okay in IE not in FF or Opera

Try adding the following to container div:

Code: Select all
#container {
width:955px;
align: center;
text-align: left;
margin-right: auto;
margin-left: auto;
margin-top:20px;
clear:both;
}
That should work...
Last Blog Entry: Windows Vista vs. Mac Leopard (Nov 4th, 2007)

Last edited by Daniel; Oct 27th, 2007 at 09:02. Reason: Please use [code] tags when posting code.
Reply With Quote
  #3 (permalink)  
Old Oct 27th, 2007, 08:31
Marc's Avatar
Moderator

SuperMember
Join Date: Apr 2007
Location: Scotland, UK
Age: 15
Posts: 1,649
Thanks: 0
Thanked 8 Times in 8 Posts
Send a message via MSN to Marc Send a message via Skype™ to Marc
Re: height: 100% Browser issues - okay in IE not in FF or Opera

Have you got a link to your problems?? Unless of course the above works
Reply With Quote
  #4 (permalink)  
Old Oct 27th, 2007, 11:24
Up'n'Coming Member
Join Date: Jun 2007
Location: Germany
Age: 23
Posts: 50
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to Lucleonhart Send a message via MSN to Lucleonhart
Re: height: 100% Browser issues - okay in IE not in FF or Opera

Did you set the html and body tag to 100% height? That is always a little mistake for wrong height definitions.
Code: Select all
html, body {
height:100%; width:100%; margin:0px; padding:0px;
}
)
Reply With Quote
Reply

Tags
cross platform issues, height, height issues

Thread Tools

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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to make a table height equal to the browser height ? subhadip Starting Out 4 Sep 20th, 2007 07:56
Browser issues with css tobymather Web Page Design 9 Apr 18th, 2007 17:19
Learn Browser Height And Enforce Window To Take At Least 95% transistortoaster Web Page Design 1 Mar 8th, 2007 16:30
Height issues? PicoDeath Web Page Design 4 Nov 2nd, 2006 08:54
browser height benbacardi JavaScript Forum 1 May 10th, 2004 20:14


All times are GMT. The time now is 18:50.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC8
© 2003-2008 Webforumz.com : All Rights Reserved

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43