User Name Password Register
DaniWeb IT Discussion Community
All
What is DaniWeb IT Discussion Community?
You're currently browsing the HTML and CSS section within the Web Development category of DaniWeb, a massive community of 374,154 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 3,449 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our HTML and CSS advertiser: Lunarpages Web Hosting
Views: 926 | Replies: 3
Reply
Join Date: Apr 2008
Posts: 3
Reputation: andre1011 is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
andre1011 andre1011 is offline Offline
Newbie Poster

<div> height

  #1  
Apr 27th, 2008
I have a <div> that will not extend all the way down the page even with the height set to 100% on the <html> and <body> and the div itself. It will not display correctly in ie7 or firefox.

I have an external style sheet but this is basicly the structure of the page

  1. <html>
  2. <head>
  3. <body>
  4. <div id="wrapper">
  5. <div id="colWrapper">
  6. </div>
  7. </div>
  8. </body>
  9. </head>
  10. </html>

CSS:
  1. html {height:100%;}
  2. body{height:100%;}
  3. #wrapper{height:100%;}
  4. #colWrapper{height:100%}
I would like any help someone can give me thanks
Last edited by peter_budo : Apr 27th, 2008 at 3:35 am. Reason: Keep It Organized - please use [code] tags
AddThis Social Bookmark Button
Reply With Quote  
Join Date: Jan 2008
Posts: 71
Reputation: amigura is an unknown quantity at this point 
Rep Power: 1
Solved Threads: 7
amigura's Avatar
amigura amigura is offline Offline
Junior Poster in Training

Re: <div> height

  #2  
Apr 27th, 2008
it works ok on ie7 and opera for me. 1 is not a ff user.

<html>
<head>
<style type="text/css">
html {height:100%;}
          body{height:100%;  background:#0066FF}
          #wrapper{height:100%; background:red}
          #colWrapper{height:100%; width:80%; background:yellow}
</style>

</head>		  
<body>
   <div id="wrapper"> wrapper text
      <div id="colWrapper"> colWrapper text
      </div>
   </div>
</body>
</html>
Reply With Quote  
Join Date: Jan 2007
Posts: 2,433
Reputation: MidiMagic is on a distinguished road 
Rep Power: 6
Solved Threads: 99
MidiMagic's Avatar
MidiMagic MidiMagic is offline Offline
Nearly a Posting Maven

Re: <div> height

  #3  
Apr 28th, 2008
Generally you can't control the vertical height of a screen object to match the size of the browser window. This is because there are too many possibilities among different browsers and window sizes.

Div is also very poorly designed and implemented. It generally assumes the height of the tallest object inside it.
Daylight-saving time uses more gasoline
Reply With Quote  
Join Date: Apr 2008
Posts: 3
Reputation: andre1011 is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
andre1011 andre1011 is offline Offline
Newbie Poster

Re: <div> height

  #4  
Apr 29th, 2008
Thanks I got it to work in ie6 still working on firefox

Originally Posted by amigura View Post
it works ok on ie7 and opera for me. 1 is not a ff user.

<html>
<head>
<style type="text/css">
html {height:100%;}
          body{height:100%;  background:#0066FF}
          #wrapper{height:100%; background:red}
          #colWrapper{height:100%; width:80%; background:yellow}
</style>

</head>		  
<body>
   <div id="wrapper"> wrapper text
      <div id="colWrapper"> colWrapper text
      </div>
   </div>
</body>
</html>
Reply With Quote  
Reply

Only community members can participate in forum threads. You must register or log in to contribute.

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 

DaniWeb HTML and CSS Marketplace
Thread Tools Display Modes

Similar Threads
Other Threads in the HTML and CSS Forum

All times are GMT -4. The time now is 3:29 am.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC