/ Published in: JavaScript
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
<!--[if lte IE 6]> <script type="text/javascript"> window.attachEvent('onload', mmwidth); window.attachEvent('onresize', mmwidth); function mmwidth(){ document.getElementById('somediv').style.width = ((document.documentElement.clientWidth || document.body.clientWidth) < 1000) ? '1000px' : ((document.body.clientWidth > 1000) ? 'auto' : 'auto'); }; </script> <![endif]-->