Is it possible to change $(window).width()
via jQuery, so that something like this is possible:
$('#click').click(function(){
//menu 100px with $(window).width();
});
No it's not. The underlying DOM element itself doesn't support modifying the width of the browser window. It is possible to change the dimensions of the content (outerWidth / innerWidth) area. However I don't believe this has an affect on the size of the window which is what you seem to want to achieve
You can control the size of a new browser window that you open with window.open()
. See https://developer.mozilla.org/En/Window.open for how to do that.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With