Forum Moderators: open

Message Too Old, No Replies

Close parent window in firefox not working

Is there a solution to pass this?

         

humpg

1:00 pm on Mar 19, 2007 (gmt 0)

10+ Year Member



I have created a web app that I want to open in a browser at a specific size. What I have so far on the main page opens the window and then closes the parent window which works fine for IE but not firefox. After searching around I see that with firefox you can't close a window that hasn't been opened by a script.

We plan to install this application on the users machine so here are my questions?

1. Has anyone figured out a way to do this in firefox?

2. Can I set parameters for a link in the start menu/desktop icon to open a browser window to my specifications?

BlobFisk

4:11 pm on Mar 19, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Hi humpg,

Not being able to close the parnet window using javascript is a security feature that won't be easy to get around using a client side script.

As for your second option, you could use a script on the page that resizes the window:


<script type="text/javascript">
window.resizeTo(500,500);
</script>

HTH

humpg

11:24 am on Mar 20, 2007 (gmt 0)

10+ Year Member



I could But I want to open the page up without all the options like scrollbars, toolbars, menu's, etc.

Xapti

7:06 pm on Mar 25, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I figured out a way to do this for Firefox. I wanted a nice media player to play my MOD files, so I had the list of hyperlinks to play the files, and a little fixed position iframe to the right which they would open in.

Anyway... I don't remember exactly what I did... I remember having to manually allow javascript from "file:\\\" addresses, and I might have had to change an option in Firefox to allow non-script opened windows to be closed. I know I did it somehow... but it involved changing settings manually... something you will not be able to do for any clients you'd be releasing this product to... so I guess this isn't much help.