|
onResize Issue in NS7.2: msg#00057mozilla.devel.dom
Hello... My name is Calvin Mitchell. My web site is http://www.clmitchell.net/ Here's my problem: I've added an external javascript file to respond to the onresize command in the body of my web page: *************************** <body id="bodygs" class="gnustep" onresize="resize()" onresize="resize()"> *************************** the javascript function works fine in IE6, but in NS7.2 it doesn't work...where did i go wrong??? following is the code for resize.js; ANY ASSISTANCE WOULD BE GREATLY APPRECIATED!! ***************************** //function for resizing gnustep page function resize(){ //IE6 if (document.all){ //if window width is too small dont change anything var parWidth=document.body.clientWidth; if (parWidth<795)parWidth=805; //make width adjustments document.all['ws1'].style.pixelWidth=parWidth-10; document.all['HTab'].style.pixelWidth=parWidth-232; document.all['DataTab'].style.pixelWidth=parWidth-232; document.all['dock1'].style.pixelLeft=parWidth-85; document.all['xhtml-compliant'].style.pixelLeft=parWidth-288; //if window height is too small dont change anything var parHeight=document.body.clientHeight; if (parHeight<595)parHeight=605; //make height adjustments document.all['ws1'].style.pixelHeight=parHeight-10; document.all['DataTab'].style.pixelHeight=parHeight-92; document.all['xhtml-compliant'].style.pixelTop=parHeight-50; //make sure everything is visible document.all['bodygs'].style.visibility = 'visible'; document.all['bodygs'].zIndex = 0; document.all['HTab'].style.visibility = 'visible'; document.all['HTab'].zIndex = 1; document.all['DataTab'].style.visibility = 'visible'; document.all['DataTab'].zIndex = 1; document.all['dock1'].style.visibility = 'visible'; document.all['dock1'].zIndex = 1; document.all['xhtml-compliant'].style.visibility = 'visible'; document.all['xhtml-compliant'].zIndex = 1; document.all['menu1'].style.visibility = 'visible'; document.all['menu1'].zIndex = 1; return; } //NS6+ if (document.getElementById){ //if window width is too small dont change anything var parWidth=window.innerWidth; if (parWidth<795)parWidth=805; //make width adjustments document.getElementById('ws1').style.width=parWidth-10; document.getElementById('HTab').style.width=parWidth-232; document.getElementById('DataTab').style.width=parWidth-232; document.getElementById('dock1').style.left=parWidth-85; document.getElementById('xhtml-compliant').left=parWidth-288; //if window height is too small dont change anything var parHeight=window.innerHeight; if (parHeight<595)parHeight=605; //make height adjustments document.getElementById('ws1').height=parHeight-10; document.getElementById('DataTab').height=parHeight-92; document.getElementById('xhtml-compliant').top=parHeight-50; //make sure everything is visible document.getElementById('bodygs').visibility = 'visible'; document.getElementById('bodygs').zIndex = 0; document.getElementById('HTab').visibility = 'visible'; document.getElementById('HTab').zIndex = 1; document.getElementById('DataTab').visibility = 'visible'; document.getElementById('DataTab').zIndex = 1; document.getElementById('dock1').visibility = 'visible'; document.getElementById('dock1').zIndex = 1; document.getElementById('xhtml-compliant').visibility = 'visible'; document.getElementById('xhtml-compliant').zIndex = 1; document.getElementById('menu1').visibility = 'visible'; document.getElementById('menu1').zIndex = 1; return; } } ***************************** |
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Re: clearing setting for style.display: 00057, Martin Honnen |
|---|---|
| Next by Date: | Re: onResize Issue in NS7.2: 00057, Martin Honnen |
| Previous by Thread: | clearing setting for style.displayi: 00057, Lee Atkinson |
| Next by Thread: | Re: onResize Issue in NS7.2: 00057, Martin Honnen |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |