Go Back   CodingForums.com > :: Client side development > JavaScript programming

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 07-03-2002, 06:56 PM   PM User | #1
Sk8er9547
New Coder

 
Join Date: Jun 2002
Location: Colorado
Posts: 66
Thanks: 0
Thanked 0 Times in 0 Posts
Sk8er9547 is an unknown quantity at this point
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
Sk8er9547 is offline   Reply With Quote
Old 07-03-2002, 07:01 PM   PM User | #2
requestcode
Regular Coder

 
Join Date: Jun 2002
Posts: 626
Thanks: 0
Thanked 0 Times in 0 Posts
requestcode is an unknown quantity at this point
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.
requestcode is offline   Reply With Quote
Old 07-04-2002, 03:42 AM   PM User | #3
A1ien51
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
A1ien51 will become famous soon enough
you can do this.....

window.resizeTo(100,100);
window.moveTo(3000,3000);
self.blur();
A1ien51 is offline   Reply With Quote
Old 07-04-2002, 05:03 AM   PM User | #4
glenngv
Supreme Master coder!


 
glenngv's Avatar
 
Join Date: Jun 2002
Location: Los Angeles, CA Original Location: Philippines
Posts: 10,241
Thanks: 0
Thanked 112 Times in 111 Posts
glenngv will become famous soon enough
cool! but in Netscape, it doesn't allow window to be positioned out of the desktop area, maybe it's a security issue.

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

window.resizeTo(100,100);
window.moveTo(3000,3000);
self.blur();
__________________
Glenn
_____________________________________________
Play Tower of Hanoi Android app (Ad-FREE!)
Play Tower of Hanoi Android app (FREE!)
Go to Tower of Hanoi Leaderboard
Play Tower of Hanoi Facebook app
glenngv is offline   Reply With Quote
Old 07-04-2002, 05:19 AM   PM User | #5
A1ien51
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
A1ien51 will become famous soon enough
I personally would do this:



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


A1ien51
A1ien51 is offline   Reply With Quote
Old 07-04-2002, 05:45 AM   PM User | #6
glenngv
Supreme Master coder!


 
glenngv's Avatar
 
Join Date: Jun 2002
Location: Los Angeles, CA Original Location: Philippines
Posts: 10,241
Thanks: 0
Thanked 112 Times in 111 Posts
glenngv will become famous soon enough
so it's not "minimize" anymore for NS?

Quote:
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
_____________________________________________
Play Tower of Hanoi Android app (Ad-FREE!)
Play Tower of Hanoi Android app (FREE!)
Go to Tower of Hanoi Leaderboard
Play Tower of Hanoi Facebook app
glenngv is offline   Reply With Quote
Old 07-04-2002, 06:22 AM   PM User | #7
A1ien51
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
A1ien51 will become famous soon enough
It will not hide it, but will just move it off to the side to keep the error from happening
A1ien51 is offline   Reply With Quote
Old 07-04-2002, 06:41 AM   PM User | #8
glenngv
Supreme Master coder!


 
glenngv's Avatar
 
Join Date: Jun 2002
Location: Los Angeles, CA Original Location: Philippines
Posts: 10,241
Thanks: 0
Thanked 112 Times in 111 Posts
glenngv will become famous soon enough
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
_____________________________________________
Play Tower of Hanoi Android app (Ad-FREE!)
Play Tower of Hanoi Android app (FREE!)
Go to Tower of Hanoi Leaderboard
Play Tower of Hanoi Facebook app
glenngv is offline   Reply With Quote
Old 07-04-2002, 07:20 AM   PM User | #9
A1ien51
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
A1ien51 will become famous soon enough
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
A1ien51 is offline   Reply With Quote
Old 07-04-2002, 07:31 AM   PM User | #10
Sk8er9547
New Coder

 
Join Date: Jun 2002
Location: Colorado
Posts: 66
Thanks: 0
Thanked 0 Times in 0 Posts
Sk8er9547 is an unknown quantity at this point
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
Sk8er9547 is offline   Reply With Quote
Old 07-04-2002, 07:46 AM   PM User | #11
A1ien51
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
A1ien51 will become famous soon enough
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
A1ien51 is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 07:51 AM.


Advertisement
Log in to turn off these ads.