Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 11 of 11
  1. #1
    New Coder
    Join Date
    Jun 2002
    Location
    Colorado
    Posts
    66
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Internet Explorer Minimize custom window

    Hi, i have a pop-up window that doesnt have any of the browser borders or anything. I was wondering if there was a simple code to have a link make the window minimize, such as:

    <a href="javascript:top.window.minimize()">minimize window</a>

    the above code does not work, and i was wondering if i was wrong....thanks for all of your help!
    -Sk8er9547

  • #2
    Regular Coder
    Join Date
    Jun 2002
    Posts
    626
    Thanks
    0
    Thanked 0 Times in 0 Posts
    With JavaScript you can't minimize a window. All you can do is remove focus from it which would place it behind the main window. Trh this:
    <A HREF="javascript:window.blur()">Minimize Window</A>

    The blur() method removes focus.

  • #3
    Senior Coder A1ien51's Avatar
    Join Date
    Jun 2002
    Location
    Between DC and Baltimore In a Cave
    Posts
    2,717
    Thanks
    1
    Thanked 94 Times in 88 Posts
    you can do this.....

    window.resizeTo(100,100);
    window.moveTo(3000,3000);
    self.blur();

  • #4
    Supreme Master coder! glenngv's Avatar
    Join Date
    Jun 2002
    Location
    Philippines
    Posts
    11,068
    Thanks
    0
    Thanked 256 Times in 252 Posts
    cool! but in Netscape, it doesn't allow window to be positioned out of the desktop area, maybe it's a security issue.

    Originally posted by A1ien51
    you can do this.....

    window.resizeTo(100,100);
    window.moveTo(3000,3000);
    self.blur();
    Glenn
    ____________________________________

    My Blog
    Tower of Hanoi Android app (FREE!)
    Tower of Hanoi Leaderboard
    Samegame Facebook App
    vBulletin Plugins
    ____________________________________

  • #5
    Senior Coder A1ien51's Avatar
    Join Date
    Jun 2002
    Location
    Between DC and Baltimore In a Cave
    Posts
    2,717
    Thanks
    1
    Thanked 94 Times in 88 Posts
    I personally would do this:



    window.resizeTo(100,100);
    if(document.all){window.moveTo(3000,3000);}
    else{window.moveTo(0,0);}
    self.blur();


    A1ien51

  • #6
    Supreme Master coder! glenngv's Avatar
    Join Date
    Jun 2002
    Location
    Philippines
    Posts
    11,068
    Thanks
    0
    Thanked 256 Times in 252 Posts
    so it's not "minimize" anymore for NS?

    Originally posted by A1ien51
    I personally would do this:



    window.resizeTo(100,100);
    if(document.all){window.moveTo(3000,3000);}
    else{window.moveTo(0,0);}
    self.blur();


    A1ien51
    Glenn
    ____________________________________

    My Blog
    Tower of Hanoi Android app (FREE!)
    Tower of Hanoi Leaderboard
    Samegame Facebook App
    vBulletin Plugins
    ____________________________________

  • #7
    Senior Coder A1ien51's Avatar
    Join Date
    Jun 2002
    Location
    Between DC and Baltimore In a Cave
    Posts
    2,717
    Thanks
    1
    Thanked 94 Times in 88 Posts
    It will not hide it, but will just move it off to the side to keep the error from happening

  • #8
    Supreme Master coder! glenngv's Avatar
    Join Date
    Jun 2002
    Location
    Philippines
    Posts
    11,068
    Thanks
    0
    Thanked 256 Times in 252 Posts
    so it's better if the code is this:

    if(document.all){
    window.resizeTo(100,100);
    window.moveTo(3000,3000);
    self.blur();
    }
    else{
    alert("Sorry, IE feature only.");
    }
    Glenn
    ____________________________________

    My Blog
    Tower of Hanoi Android app (FREE!)
    Tower of Hanoi Leaderboard
    Samegame Facebook App
    vBulletin Plugins
    ____________________________________

  • #9
    Senior Coder A1ien51's Avatar
    Join Date
    Jun 2002
    Location
    Between DC and Baltimore In a Cave
    Posts
    2,717
    Thanks
    1
    Thanked 94 Times in 88 Posts
    I wouldn't want to see an alert, I would do it the way I did it.
    You could also get a signed script for netscape to move it off of the screen or make it smaller. Look at netscapes website on programming for that

  • #10
    New Coder
    Join Date
    Jun 2002
    Location
    Colorado
    Posts
    66
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Thanks for everything guys! Now i have a problem with moving the window. I want to be able to move the custom window around to any position using click and drag, just like you could in a normal web browser. Any ideas?
    -Sk8er9547

  • #11
    Senior Coder A1ien51's Avatar
    Join Date
    Jun 2002
    Location
    Between DC and Baltimore In a Cave
    Posts
    2,717
    Thanks
    1
    Thanked 94 Times in 88 Posts
    LOL....expecting me to give all of my secrets away......??

    Right now I have developed a fully functional window which you are trying to do.......but the code is 2hrs away, so I can not finish it...ugh......Oh welll.....

    look on Dynamic Drive, they have a window like you want.....

    Mine will be posted on my site sometime this weekend I hope....

    Send me an email at A1ien51@hotmail.com and I will send you an email telling you when I put it online.

    A1ien51


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •