Closed Bug 227717 Opened 21 years ago Closed 21 years ago

Resizing child window doesn't work

Categories

(SeaMonkey :: General, defect)

x86
Windows XP
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED DUPLICATE of bug 142375

People

(Reporter: idobeeri, Unassigned)

References

()

Details

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.5) Gecko/20031007
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.5) Gecko/20031007

Go to this site: http://www.twinadv.com/new/index.php?action=14&dir=atresica
Click on an link, a child window opens. Click on another link, the link is
opened in the same child window, but it doesn't resize the child window as it
should. IE doesn't have this problem.

I tried to make a testcase, but with no success. This site won't be there for
too long, so I would appreciate if someone will make a testcase.

Reproducible: Always

Steps to Reproduce:
Summary: Resizing child window → Resizing child window doesn't work
Works fine with Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.6b)
Gecko/20031202

I think that recently there was a problem with the window.open, so you should
try with a current nightly and make sure that you aren't blocking the resize of
windows in your preferences (Advances->scripts & plugins)
I upgraded my Mozilla to the latest nighly buid, and the bug still isn't fixed.
Maybe you didn't understand my bug report:

1. the child window DOES resize to the right size when it is created
2. the child window DOESN'T resize again when you click on another link that is
opened in the child window that's already open

*** This bug has been marked as a duplicate of 142375 ***
Status: UNCONFIRMED → RESOLVED
Closed: 21 years ago
Resolution: --- → DUPLICATE
I don't think that this is a dup of 142375. That example doesn't work, but this
one is a WFM. The child window resizes whenever I click on any of those links.
Not just when the window is opened.

besides that the code isn't just a window.open as bug 142375

function popup(url,width,height){
	var parameters =
"scrollbars=no,menubar=no,titlebar=no,status=no,directories=no,toolbar=no,resizable=no,width="+width+",height="+height;
	windowhandle = window.open('image.php?url=' + url, 'Preview', parameters)
	windowhandle.focus();
	windowhandle.resizeTo(width + 10, height + 28);
}

reopening

I'm gonna search for the bug of comment 1
Status: RESOLVED → UNCONFIRMED
Resolution: DUPLICATE → ---
Works for me too, but I have to allow JavaScript to resize windows first.
(Maybe it should work without that pref in this case?)
Looking at the code in comment 5, I agree with Boris, this is bug 142375.
The reason it works in Mozilla is the 'resizeTo' call - but it requires JS
permissions...
Ido, which version of IE are you using?
If you manually move the popup window after opening the first image and then
click on another link - does the popup window stay where it is?
If you try the same with links to HTML files instead of images - does IE
behave the same in this case regarding resizing and positioning?
I just tested it with Mozilla on another computer, and it's ok! :)

Nevertheless, on my computer it's still happening.
> I just tested it with Mozilla on another computer, and it's ok! :)

Yes, it works fine if you have the right JS permissions in your Preferences...

I'd really appreciate if you could answer my questions in comment 8.  Thanks.
I'm using IE 6.0
And for the rest of the questions: Yes
OK, thanks for your help.  This is a dupe of bug 142375 then (which I intend
to reopen).

If you enable "Allow scripts to: Move or resize existing windows" under 
Preferences / Advanced / Script & plug-ins the URL will work as expected.

*** This bug has been marked as a duplicate of 142375 ***
Status: UNCONFIRMED → RESOLVED
Closed: 21 years ago21 years ago
Resolution: --- → DUPLICATE
Product: Browser → Seamonkey
You need to log in before you can comment on or make changes to this bug.