Home:ALL Converter>How to disable minimize, maximize button in the browser?

How to disable minimize, maximize button in the browser?

Ask Time:2011-01-21T10:24:48         Author:VJS

Json Formatter

How to disable minimize, maximize button in the browser using JavaScript?

Author:VJS,eproduced under the CC 4.0 BY-SA copyright license with a link to the original source and this disclaimer.
Link to original article:https://stackoverflow.com/questions/4754823/how-to-disable-minimize-maximize-button-in-the-browser
Jonathon Faust :

You cannot (consistently). Deliberately malicious actions are generally restricted by browsers.",
2011-01-21T02:27:25
squillman :

window.open(\"mypage.html\",\"mywindowname\", \"toolbar=no,menubar=no\");\n\n\nWIll give you a new window without the menubar and without the toolbar. That's what I'm assuming you want when you say \"disable\". If you just want to disable the functionality while still showing the buttons, then you can't.\n\nLook here for a reference on the window.open() method.",
2011-01-21T02:28:30
Tom :

Here is another approach, you can send key strokes for Alt, Space,N.\n\n <SCRIPT LANGUAGE=\"JavaScript\">\n\nvar WshShell = new ActiveXObject(\"WScript.Shell\");\nfunction Minimize()\n{\n WshShell.SendKeys(\"% n\");\n}\n</SCRIPT>\n\n</HEAD>\n\n<BODY >\n<TABLE width=100%>\n<TR align=right>\n <TD><input type=\"button\" name=\"Button\" onclick=\"Minimize()\" value=\"minimize\" /></TD>\n</TR>\n</TABLE>\n\n</BODY>\n",
2011-08-04T16:12:48
yy