Closed Thread Icon

Preserved Topic: Netscape resize error Pages that link to <a href="https://ozoneasylum.com/backlink?for=17728" title="Pages that link to Preserved Topic: Netscape resize error" rel="nofollow" >Preserved Topic: Netscape resize error\

 
Author Thread
lloydhass
Nervous Wreck (II) Inmate

From: Melbourne, Australia
Insane since: Apr 2000

posted posted 05-24-2000 07:33

I am having troubles when the window is resized in NN. I have a script which move, shows & hides layers but when the window is resized, it stops working.<P>I remember reading about a NN resize script here some time ago but cannot find it. Can someone help me?<P>http://go.to/hass

DL-44
Maniac (V) Inmate

From: under the bed
Insane since: Feb 2000

posted posted 05-24-2000 07:42

yes, I posted the same question some time ago (it should be in the dhtml/javascript archive), but never really got much of an answer. I know Doc himself has a script which helps, but it didn't actually fix anything for me. All I can say is, warn netscape users to reload if they resize....<P>What care I how time advances? I am drinking Ale today. -- Edgar Allen Poe

eedn
Bipolar (III) Inmate

From: Midlothian, VA USA
Insane since: Mar 2000

posted posted 05-24-2000 15:09

I use this this code in my pages and unless I missed something while copying and pasting it into here it should work for you guys. Make sure that you put onLoad="init()" in your <body> tag. I know it seems like a lot of code and there is probably another way, but this one's tried, trued, and tested...<P><script language="JavaScript">
<!--<P>ie4 = (document.all)?1:0;
ns4 = (document.layers)?1:0;<P>function resObj() {
this.x = (ns4)?innerWidth:document.body.offsetWidth;
this.y = (ns4)?innerHeight:document.body.offsetHeight;
}<P>function init() {
page = new resObj();
window.onresize = resizeIt;
}<P>function resizeIt() {
page2 = new resObj()
if(page2.x != page.x

jiblet
Paranoid (IV) Inmate

From: Minneapolis, MN, USA
Insane since: May 2000

posted posted 05-24-2000 17:20

Funny, I just saw a tip about this from Doc Javascript over at Webreference.com. I just looked again and can't find it, but look around yourself at http://www.webreference.com/js/

DocOzone
Maniac (V) Lord Mad Scientist
Sovereign of all the lands Ozone and just beyond that little green line over there...

From: Stockholm, Sweden
Insane since: Mar 1994

posted posted 05-25-2000 01:04

I'll tell you, I'm skeptical. I've tried this code and others, and written my own, and here's what appears to happen. When Netscape reszes the window, it doesn't process the styles or javascripts on the page. The script detects the width of the window, and if it changes, it reloads. But! The script wasn't recognized the second time around, and the script that's checking things doesn't work anymore, what will probably happen? Nothing at all, in my experience. YMMV.<P><IMG SRC="http://www.ozones.com/forum/siggie.gif" border=0>

DL-44
Maniac (V) Inmate

From: under the bed
Insane since: Feb 2000

posted posted 05-25-2000 06:15

YMMV????<P>------------<P>:::What care I how time advances? I am drinking Ale today. -- Edgar Allen Poe:::

lloydhass
Nervous Wreck (II) Inmate

From: Melbourne, Australia
Insane since: Apr 2000

posted posted 05-25-2000 06:15

Thankyou all for your quick responses. I guess I am not the only person who has experienced this Netscape problem. That is an interesting piece of code eedn. I found this over at www.dynamicdrive.com attached to most of their scripts.<P><BLOCKQUOTE><font size="1" face="Verdana, Arial">code:</font><HR><pre>if (document.layers) {
window.onresize = new Function("location.reload()");
}</pre><HR></BLOCKQUOTE><P>Seeing this problem occurs in Nestcape every time the window resizes, the above code is much easier to use and does the same thing. I guess I will have to add this to all my Dhtml scripts.

DocOzone
Maniac (V) Lord Mad Scientist
Sovereign of all the lands Ozone and just beyond that little green line over there...

From: Stockholm, Sweden
Insane since: Mar 1994

posted posted 05-25-2000 08:53

var YMMV = "Your Mileage May Vary";

« BackwardsOnwards »

Show Forum Drop Down Menu