Closed Thread Icon

Preserved Topic: How do I use percent in IE? Pages that link to <a href="https://ozoneasylum.com/backlink?for=17864" title="Pages that link to Preserved Topic: How do I use percent in IE?" rel="nofollow" >Preserved Topic: How do I use percent in IE?\

 
Author Thread
SCarab
Nervous Wreck (II) Inmate

From:
Insane since: Jun 2000

posted posted 09-20-2000 04:48

Ok... I've been making a bunch of pages, and testing them in Netscape (on my Mac), and figured that fixing things up for IE (5.0 for the Mac) wouldn't be awful, since I've been pretty careful to keep things clean and simple, and have a separate section of a setup funtion devoted to each browser. But when I try to use "width=50%", for example, TheLayer.left doesn't give me anything.

I'd like to be able to use the width of an invisible layer to tell me how wide the person's browser window is, and use that information elsewhere. It works fine in Netscape, but I can't seem to get it to work in IE. Any suggestions?

Thanks in advance.
--SCarab

little osh
Bipolar (III) Inmate

From: Wales, UK
Insane since: Jun 2000

posted posted 09-20-2000 05:34

You can get the browser's width in a diferent way you know.

in NS4 use
browserWidth = innerWidth;
browserHeight = innerHeight;

in IE4 (and 5 I assume)
browserWidth = document.body.clientWidth;
browserHeight = document.body.clientHeight;

Does that make things simpler?

osh

SCarab
Nervous Wreck (II) Inmate

From:
Insane since: Jun 2000

posted posted 09-20-2000 06:10

There were other things I was thinking of doing with the percentages, but now that you mention it, I see that I can do pretty much all of those things using the browser width and height. So, yes, that does help quite a bit. Thanks. <img border=0 align=absmiddle src="http://www.ozones.com/forum/smile.gif">

--SCarab

« BackwardsOnwards »

Show Forum Drop Down Menu