ck969
11-29-2002, 09:38 AM
When I resize my browser, on the <body> tag, how could I call a function and return the current browser width ?
|
Click to See Complete Forum and Search --> : How to get browser width when resized ck969 11-29-2002, 09:38 AM When I resize my browser, on the <body> tag, how could I call a function and return the current browser width ? gil davis 11-29-2002, 11:20 AM <script> window.onresize = myResize; function myResize() { if (document.all) {alert(document.body.clientWidth);} else {alert(window.innerWidth);} } </script> I'm not sure why you think the <body> has to have the script. webdeveloper.com
Copyright WebMediaBrands Inc., All Rights Reserved. |