Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

CSS Forum


You are currently viewing our CSS Forum as a guest. Please register to participate.
Login



Reply
<div> 100% Of The Browser Height
Old 07-06-2006, 04:37 PM <div> 100% Of The Browser Height
Miki's Avatar
Skilled Talker

Posts: 72
Name: Michael Stubbs
Location: Warrington, UK
Trades: 0
Hello, long-time no-see.

Anyway, I was wondering, is it possible to make a div 100% of the browser height?

I tryed 100%, min-height. I've tryed searching on google but 99.9% of the things I find is just vertical div alignment.

For example, I have a page at the moment, a very simple page. There is a header div thats 75% of the page width and next to it is supposed to be a "sidebar" type thing that would look very nice at 100% of the page height.

I've tryed setting the div to 600px, but one size doesnt fit all unfortunatly.


Thank you in advance for any replies and talkupation will be given to those with helpful answers.
Miki is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 07-06-2006, 05:49 PM Re: <div> 100% Of The Browser Height
Skilled Talker

Posts: 92
Trades: 0
Set your body height to 100%. From everything I've read, the div height works off of what it's inside and not the browser height.

Example
__________________

Please login or register to view this content. Registration is FREE
Entertaining at least a few people every Monday night from 4-6 pm EST.
waffles is offline
Reply With Quote
View Public Profile Visit waffles's homepage!
 
Old 07-06-2006, 05:58 PM Re: <div> 100% Of The Browser Height
LadynRed's Avatar
Defies a Status

Posts: 10,016
Location: Tennessee
Trades: 0
First of all, min-height is just that.. minimum and it doesn't work.
This obsession with having to fill the viewport escapes me, but all newbies seem to want to do it.

http://css-discuss.incutio.com/?page...dPercentHeight
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

LadynRed is offline
Reply With Quote
View Public Profile
 
Old 07-06-2006, 09:06 PM Re: <div> 100% Of The Browser Height
kIDJOE's Avatar
Extreme Talker

Posts: 186
Location: Hollywood, CA
Trades: 0
Quote:
...fill the viewport escapes me, but all newbies seem to want to do it.


Everyone has the right to be willing to make a div 100% height. If you need to develop certain functionality LadynRed, like covering an entire application with a transparent layer while background processes run to avoid the end user to click on, or to cover text to avoid its reproduction, or any server-side level you may need a wait.... Even Plesk uses this type of layers for their web server control panel software and I don't consider Plesk a newby.

and YES you can set a DIV to 100% height if its container has been set to a 100% height as well, if the very <body> is containing your DIV you can just set the Body style to 100% height.
__________________

Please login or register to view this content. Registration is FREE
-
Please login or register to view this content. Registration is FREE
-

Please login or register to view this content. Registration is FREE
-
Please login or register to view this content. Registration is FREE


Last edited by kIDJOE; 07-06-2006 at 09:10 PM..
kIDJOE is offline
Reply With Quote
View Public Profile Visit kIDJOE's homepage!
 
Old 07-06-2006, 11:09 PM Re: <div> 100% Of The Browser Height
Skilled Talker

Posts: 92
Trades: 0
The look of frames maybe. Maybe other reasons. Here's an idea, maybe I don't want my content to spread out and fill the area under the navigation. It happens, so don't make him feel bad about asking a question.
__________________

Please login or register to view this content. Registration is FREE
Entertaining at least a few people every Monday night from 4-6 pm EST.
waffles is offline
Reply With Quote
View Public Profile Visit waffles's homepage!
 
Old 07-06-2006, 11:26 PM Re: <div> 100% Of The Browser Height
kIDJOE's Avatar
Extreme Talker

Posts: 186
Location: Hollywood, CA
Trades: 0
Thats what Im saying
__________________

Please login or register to view this content. Registration is FREE
-
Please login or register to view this content. Registration is FREE
-

Please login or register to view this content. Registration is FREE
-
Please login or register to view this content. Registration is FREE

kIDJOE is offline
Reply With Quote
View Public Profile Visit kIDJOE's homepage!
 
Old 07-06-2006, 11:49 PM Re: <div> 100% Of The Browser Height
ADAM Web Design's Avatar
Canadastaninianite

Posts: 5,938
Name: Adam for web page design, not program
Location: Toronto, Ontario, Canada
Trades: 0
Actually, that argument doesn't really apply with Plesk or the height. If background processes need to run, a redirect once done will accomplish that purpose.

If you want the background to fill the viewport, then add it as a body attribute. The content itself should be resizeable.

So there really isn't a reason to do it.

Miki: what are you trying to accompish?
__________________

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
(my blog)


Please login or register to view this content. Registration is FREE
(with proof)
ADAM Web Design is offline
Reply With Quote
View Public Profile Visit ADAM Web Design's homepage!
 
Old 07-07-2006, 10:53 AM Re: <div> 100% Of The Browser Height
LadynRed's Avatar
Defies a Status

Posts: 10,016
Location: Tennessee
Trades: 0
I wasn't trying to make anyone feel bad, I gave him the solution didn't I ????
It IS a common question among newbies... I've seen it a million times.
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

LadynRed is offline
Reply With Quote
View Public Profile
 
Old 07-07-2006, 03:08 PM Re: <div> 100% Of The Browser Height
kIDJOE's Avatar
Extreme Talker

Posts: 186
Location: Hollywood, CA
Trades: 0
my Plesk theme SHows a DIV while trying to run processes and hides it when done, anyway thats not what Miki needs, the question was how to set a DIV's Height to 100%. thats all and its doable
__________________

Please login or register to view this content. Registration is FREE
-
Please login or register to view this content. Registration is FREE
-

Please login or register to view this content. Registration is FREE
-
Please login or register to view this content. Registration is FREE

kIDJOE is offline
Reply With Quote
View Public Profile Visit kIDJOE's homepage!
 
Old 07-07-2006, 04:41 PM Re: <div> 100% Of The Browser Height
ADAM Web Design's Avatar
Canadastaninianite

Posts: 5,938
Name: Adam for web page design, not program
Location: Toronto, Ontario, Canada
Trades: 0
But is it pure CSS or CSS and Javascript? It sounds like a combination of both, which would allow for a div (or any other element) to be resized to fit the entire viewport.
__________________

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
(my blog)


Please login or register to view this content. Registration is FREE
(with proof)
ADAM Web Design is offline
Reply With Quote
View Public Profile Visit ADAM Web Design's homepage!
 
Old 07-07-2006, 05:08 PM Re: <div> 100% Of The Browser Height
kIDJOE's Avatar
Extreme Talker

Posts: 186
Location: Hollywood, CA
Trades: 0
no man... you CAN really set a div's height to a 100% and of course the show and hide is Javascript. that's anyway out of this thread.

__________________

Please login or register to view this content. Registration is FREE
-
Please login or register to view this content. Registration is FREE
-

Please login or register to view this content. Registration is FREE
-
Please login or register to view this content. Registration is FREE


Last edited by kIDJOE; 07-07-2006 at 05:10 PM..
kIDJOE is offline
Reply With Quote
View Public Profile Visit kIDJOE's homepage!
 
Reply     « Reply to <div> 100% Of The Browser Height
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.94891 seconds with 12 queries