Full screen div, width + height

E

eggie5

Hi,

How can I make a div to be 100% width and height of my window? I know
with CSS I can make the width work with width:100%, however that
doesn't work for the height. Maybe I need to use javascript to get the
height of the window....?

What I'm trying to do is make the div cover the whole window with a 50%
transparent layer. I already have the transparency working, but I can
get the height to cover the whole window, how can I do this?
 
I

Ivo

How can I make a div to be 100% width and height of my window? I know
with CSS I can make the width work with width:100%, however that
doesn't work for the height. Maybe I need to use javascript to get the
height of the window....?

Add body{height:100%} as a first rule to combat what has been called an
IE-bug.
Or post an url or smaple code.

Cheers,
chicken4?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,537
Members
45,023
Latest member
websitedesig25

Latest Threads

Top