[Webdev] Sizing content automatically
Philip Reynolds
phil at redbrick.dcu.ie
Tue Sep 26 09:38:32 IST 2000
Niall O Broin's [niall at magicgoeshere.com] 22 lines of dribble included:
:>Hi,
:> I use the javascript window properties innerWidth and innerHeight to
:>determine how much content to show to a user. This works with Navigator 4
:>but not with IE 4. There, I use screen.availWidth and screen.availHeight but
:>that's not a great solution for someone who doesn't have their browser
:>window maximised.
:>
:>It's like a dream to me that I saw mentioned somewhere that this can be done
:>in IE5, although not quite as simply. Do any of you know if this is the case
:>or not ? If so, how do I do it ?
IE4 way is,
doc_width = document.body.clientWidth;
doc_height = document.body.clientHeight;
Phil.
More information about the Webdev
mailing list