469,333 Members | 4,210 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,333 developers. It's quick & easy.

disable minimize

20
Hello,

I have a html page with javascript in it.
How do I disable the minimize (the box with the underscore in it in the corner)?
I know there are already several people who asked the same question and the answers are useful like from this:
http://www.thescripts.com/forum/thread92828.html

but the solutions don't work exactly the way I want.

putting onblur="this.focus()" in the body does keep the page from being minimized, but then I can't type anything in my textboxes.

When I use the showModalDialog Method, the javascript timer that refeshed my page every five minutes doesn't work anymore.

When I use this: window.open("page.html"...resizable=0);
only the Maximize/restore down button on the top middle is disabled. The minimized wasn't disabled.

Is there another way? Or should one of these work if used correctly?

Thank you for your time.
Mar 10 '08 #1
5 2331
acoder
16,027 Expert Mod 8TB
First of all, ask yourself if you really need this. Assuming that this is needed and there is no alternative, show your child and parent window code or a link.
Mar 10 '08 #2
fluff
20
I made this program for a kiosk where people pretty much come in, type in their info, click submit and wait for their number to be called.

I have this javascript in the head part of my html.
The page will refresh every five minutes and the page will go back to full page if the size was changed.
I also have it so if the user starts inputting into the textbox, a two minute timer starts and will submit itself if the user forgets to submit so their info isn't just sitting there on the screen.

So what I want really is if the minimize was clicked, the page will pop back up at full size, or make it so that they cannot minimize at all.

Expand|Select|Wrap|Line Numbers
  1. <script Language="JavaScript">
  2. self.moveTo(0,0);self.resizeTo(screen.availWidth,screen.availHeight); 
  3.  
  4. var timerID ="";
  5.  
  6. timerID = setTimeout("window.location.reload(true);",300000);
  7.  
  8. function restartTimer()
  9. {
  10. if (timerID != ""){
  11. clearTimer();}
  12.  
  13. startTimer();
  14. }
  15.  
  16. function startTimer()
  17. {
  18. timerID = setTimeout("document.myform.submit();",120000);
  19. }
  20.  
  21. function clearTimer()
  22. {
  23. clearTimeout(timerID);
  24. }
  25. </script>
Mar 10 '08 #3
rnd me
427 Expert 256MB
if the refresh code is broken by an otherwise usable solution, fix the refresh code.

you can do it without js
Expand|Select|Wrap|Line Numbers
  1. <meta http-equiv="refresh" content="300"/>
  2.  
will refresh every 5 mins, put it in your head.
Mar 10 '08 #4
fluff
20
if the refresh code is broken by an otherwise usable solution, fix the refresh code.

you can do it without js
Expand|Select|Wrap|Line Numbers
  1. <meta http-equiv="refresh" content="300"/>
  2.  
will refresh every 5 mins, put it in your head.

rnd me,

Thank you. You're timer code works fine, but is the minimized page suppose to become active again when the timer is up?
The minimized page just stays minimized.
Mar 11 '08 #5
rnd me
427 Expert 256MB
you can use line number 2 of code from post number 3 in your body tag to perform likewise resizing.

<body onload="self.mo...">
Mar 11 '08 #6

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

1 post views Thread by Prashant Joshi | last post: by
reply views Thread by Susan | last post: by
11 posts views Thread by M O J O | last post: by
1 post views Thread by shivakanth | last post: by
1 post views Thread by CARIGAR | last post: by
reply views Thread by suresh191 | last post: by
reply views Thread by Marylou17 | last post: by
1 post views Thread by Marylou17 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.