Herbert Demmel

Navigation

Skip navigation.

Search

Site navigation

Email conversation

FromHerbert Demmel
ToMe
SubjectProblem with Netscape 7.1 and your popImageExtra()
Date4 January 2005 16:52
Hi Mark,

I'm just working on the layout of my new web layout and happily found your
web-site 'Perfect popups'. I've tried to use popImageExtra() - see the
example at [demonstration address] by clicking to the small screenshot at
the end of the page (sorry, the contents currently is in German langauge
only). It perfectly works with IE, but on Netscape 7.1 the window gets to
small :-(

changing
        'var x = window; x.resizeTo( oW + 200, oH + 200);\n'+
to
        'var x = window; x.resizeTo( oW + 200 - 25, oH + 200);\n'+

in your script would bypass the problem, but is not the really solution
... any idea, what's going wrong?
You Java Script is at [address of the copy of my script]

I've also tried to use your 'Resizing the popups to fit non-image content
of unknown width' script and have the problem that my window gets too high
- see example 'Numbering system for iLCD Panels' on my test page
('Numbering system for iLCD Controllers' goes ok on my 1152x64 pixel
monitor). I've tried to limit the height to 5/6 of the available height but
again there are problems with Netscape and it's scroll bar (IE obviosly
calculates the inner part correct as the scroll bar is ALWAYS there,
Netscape removes the scroll bar when there is nothing to scroll). Any ideas
how to fix that rpoblem? I have to say, that I do not 'speak' Java Script
(ask me in C++ or C or ASM for tiny microcontrollers and I'll understand
you ;-) ). If currently made a workaround by adding 25 pixel in widht when
I limit the height - file [sample address]

Besides the two little problems I like your Scrips very, very much, these
where the only things I could find on the web which fits my needs.

Thank you in advance for your help!

Have a happy new year!

Herbert
FromMe
ToHerbert Demmel
SubjectRe: Problem with Netscape 7.1 and your popImageExtra()
Date4 January 2005 22:53
Herbert,

This is most puzzling. I do not have Netscape 7.1 to test, and Netscape now
only offer 7.2, which is a very different browser. (And to be honest, since
Netscape is just Mozilla [NS 7.1-] or Firefox [NS 7.2], but with a huge
pile of ugly AOL branding, propaganda and advertising, you would be much
better off using the Mozilla or Firefox browsers as distributed by
mozilla.org.)

Anyway, I could not reproduce the first problem on Windows, using Mozilla,
Netscape 7.0. However, I could reproduce it using my own example and yours
using Firefox on Linux (I also managed to produce it with your example on
Windows). There is no scripting solution for it, as it is a bug in the
browser's window handling, and DOM element properties. When the script asks
it for the width of the DIV that contains the content, it gets it right
first time with my example only (it gets yours wrong every time). Once the
image is in my cache, it goes wrong every time, as the div is actually
shrunk to smaller than the image it contains.

Bizare, and very hard to track down the source of the bug. If I can produce
a minimal example, I will report it to Mozilla, so hopefully, they can fix
it in a future release.

As for the second problem, with the window being made too big when trying
to fit the contents of the tables. The problem is that you are running out
of space. Although it looks like there is a lot of space around the outside
of the window, the script needs a lot of extra space to do its resizing
(about 250 pixels). As a result, the browser limits the window size, which
confuses the script as it tries to de its final resize calculation.

The only option is to reduce the amount of content in the window. Note, I
also get the same problem with the image popup when I use a 1024 x 768
resolution - the image you are using is a bit too tall - it might be more
useful to put the smaller window in the image beside the larger one,
instead of on top of it.

A bit unfortunate, but there is not much else that can be done.

Mark 'Tarquin' Wilton-Jones - author of http://www.howtocreate.co.uk/
This site was created by Mark "Tarquin" Wilton-Jones.
Don't click this link unless you want to be banned from our site.