Applet 'showDocument' tester

  • Thread starter Andrew Thompson
  • Start date
A

Andrew Thompson

Given the recent spate of tools that knobble
a browser's ability to use the showDocument
method, I threw together a simple page to allow
users to test their browsers.
<http://www.physci.org/test/showdoc/>

While this problem has become most obvious
with new 'Pop-Up' windows, there are other
forms of showDocument that are also unreliable.
My Mozilla 1.3, for example, fails to act on
*any* of the different forms of showDocument().

[ Note, of course, that the JavaDocs mark the
showDocument method as 'optional'..,
while AppletContext.showDocument(URL) says..

"This method may be ignored by applet
contexts that are not browsers.",

...the form AppletContext.showDocument(URL, String)
goes further, stating..

"An applet viewer *or* browser is free to
ignore showDocument."

...so if a browser fails to act on it, the
browser is still not technically 'broken'. ]

HTH
 
S

Sudsy

Andrew Thompson wrote:
<snip>

Test results on Netscape 7.1/Linux:
java.lang.UnsupportedClassVersionError: RedirectApplet (Unsupported
major.minor version 48.0)
 
A

Andrew Thompson

java.lang.UnsupportedClassVersionError: RedirectApplet (Unsupported
major.minor version 48.0)

...uggh. How stupid of me. Forgot to
both compile *and* test in 1.1.

Just uploaded the recompiled version, tested
in MSVM and NN 4.8 (Symantec 1.1.5 VM)

We should be right to go.
 
S

Sudsy

Andrew said:
Just uploaded the recompiled version, tested
in MSVM and NN 4.8 (Symantec 1.1.5 VM)

We should be right to go.

Now all three tests are successful.
 
A

Andrew Thompson

Andrew said:
Now all three tests are successful.

Thanks, Sudsy.

We got any other folks willing to throw
their 'test subject' (OK ..browser) at
my showDocument test page?

Are you lurking Thufir? I would especially
like to hear the results from your Opera UA.
 
C

Chris Uppal

Andrew said:
We got any other folks willing to throw
their 'test subject' (OK ..browser) at
my showDocument test page?

FWIW:

With Mozilla Firebird 0.7, options to Block Popup Windows turned on (natch!),
Java and JavaScript both enabled, but all the subsidiary "Advanced JavaScript
Options" turned off (move windows, resize, raise, etc.) except the ability to
"Change images".

Test1: fails after a while with "This browser will not change to a new page
when Java asks it to". The 'alternate instructions' tell me that the browser
is configured to ignore meta refresh requests and has JavaScript disabled
(neither of which are true).

Test2: fails after a while with: "This browser will not show a page in a named
frame!"

Test3: just sits there and never does anything.

(OK, Firebird 0.7 is an out-of-date beta, but it /is/ what I'm currently using
for real browsing.)

-- chris
 
A

Andrew Thompson

Test1: fails after a while with "This browser will not change to a new page
when Java asks it to". The 'alternate instructions' tell me that the browser
is configured to ignore meta refresh requests and has JavaScript disabled
(neither of which are true).

Aaah... My bad, that 'alternate' link
needs to be tweaked.
(OK, Firebird 0.7 is an out-of-date beta, but it /is/ what I'm currently using
for real browsing.) ..

Ever the difficult one, I notice. ;-)
But then, this page needs to be able
to deal with all comers.

Thanks for your results.
 
M

Michiel Konstapel

We got any other folks willing to throw
their 'test subject' (OK ..browser) at
my showDocument test page?

Are you lurking Thufir? I would especially
like to hear the results from your Opera UA.

All tests are succesful on my Opera 7.23 on WinXP.
HTH,
Michiel
 
A

Andrew Thompson

All tests are succesful on my Opera 7.23 on WinXP.

Thanks for the feedback Michiel.

The specific reference to Opera was in
relation to a pop-up blocker that the latest
(Linux at least?) Opera has built-in(??).

Though looking at the Opera site, I could
find no mention of a pop-up blocker being
provided with either the Win or Linux
installs..

Maybe Thufir got his as a third party plug-in?
 
S

Sudsy

Andrew Thompson wrote:
The specific reference to Opera was in
relation to a pop-up blocker that the latest
(Linux at least?) Opera has built-in(??).

In the interest of completeness, the Netscape 7.1/Linux version
I'm running has a very effective pop-up blocker. The complete
specification is as follows:
"Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.0.2) Gecko/20021120
Netscape/7.01"

It doesn't prevent the JavaScript pop-up from Hotmail which asks
(ad nauseum) "Are you sure you want to permanently delete all
messages in this folder?", which is a good thing.
OTOH, it effectively blocks the pop-ups from a local newspaper
which I read on-line.
Overall I'm both impressed and satisfied. It's a winning effort
in my book!
YMMV
 
A

Andrew Thompson

...Netscape 7.1/Linux version
I'm running has a very effective pop-up blocker. ....
It doesn't prevent the JavaScript pop-up from Hotmail which asks
(ad nauseum) "Are you sure you want to permanently delete all
messages in this folder?", which is a good thing.
OTOH, it effectively blocks the pop-ups from a local newspaper
which I read on-line.

OK. It is interesting that the Netscape
pop-up blocker does *not* suppress the
'open in blank window' showDocument call,
I am surprised...
 
J

Jaakko Kangasharju

Andrew Thompson said:
The specific reference to Opera was in
relation to a pop-up blocker that the latest
(Linux at least?) Opera has built-in(??).

Here, Opera 7.53 for Linux, using the built-in pop-up blocker, all
tests are successful.
 
J

John C. Bollinger

Andrew said:
We got any other folks willing to throw
their 'test subject' (OK ..browser) at
my showDocument test page?

Mozilla 1.6 with popup blocker on / Win2K / JRE 1.4.2: all tests are
successful.


John Bollinger
(e-mail address removed)
 
A

Andrew Thompson

Mozilla 1.6 with popup blocker on / Win2K / JRE 1.4.2: all tests are
successful.

Thanks John.. I must admit I am surprised
(and a little cautious of) all the positive
results for browser's with pop-up blockers.

I keep looking around, expecting the makers of
the pop-up blocking software to go "hey, ..wait
a minute now, we've missed one type."

Maybe it is that Java developers are 'all too
innocent' to realize the potential to abuse
these things (at least for a month or two
before the pop-up blockers makers get their
act together, or UA manufacturers are forced
to add a 'Block Java Pop-Ups', or 'Ignore
Java Page Change Requests' ..as Mozilla 1.3
seems to.)
 
G

Grant Wagner

Andrew said:
Thanks John.. I must admit I am surprised
(and a little cautious of) all the positive
results for browser's with pop-up blockers.

I would suggest that Gecko-based browsers are popup blocking based on
client-side script only. A new window opened by the showDocument() method
in a Java Applet (or any other way) is simply ignored, rather than noticed
and allowed to continue.

The Google toolbar and the IE popup blocker in Windows XP SP2 on the other
hand, notice the unrequested[1] new window opening and block it. They have
no way of knowing that a request to load <A HREF='applet.jsp?part=3'
TARGET='content'>Test 3</A> prompted the opening of a new window, and, in
my opinion, correctly block it.

If the request to open the new window is as a direct user action _inside_
the Applet, popup blockers _should_ allow it, but almost certainly (in the
case of Google and the XP SP2 one) _will not_. Again, the popup blockers
have no magical knowledge of what goes on inside the Applet, all they see
is a new unrequested[1] window being opened.

[1] - unrequested as defined by the popup blocker authors. Apparently
Google and Microsoft feel any new window opening that was not a direct
result of "Open in New Window", a TARGET attribute or a window.open()
initiated somewhere near a user-fired event is unrequested.
I keep looking around, expecting the makers of
the pop-up blocking software to go "hey, ..wait
a minute now, we've missed one type."

If there is enough abuse of this "feature", I'm sure you will see the
popup blocker in Gecko-based browsers begin to mimic those of the Google
toolbar and IE. They will watch for new "unrequested" windows opening and
take steps to stop them.
Maybe it is that Java developers are 'all too
innocent' to realize the potential to abuse
these things (at least for a month or two
before the pop-up blockers makers get their
act together, or UA manufacturers are forced
to add a 'Block Java Pop-Ups', or 'Ignore
Java Page Change Requests' ..as Mozilla 1.3
seems to.)

Personally I figure it's that most of the scum that depend on such tactics
are not skillful enough to do the work themselves, and are too cheap to
hire someone who can do it for them. "Popup scripts" of various kinds are
freely available on the Web, no special talent is required to copy/paste
someone else's annoying popup code into your own page, but doing it using
a Java Applet introduces a level of complexity most site authors are
simply not capable of achieving.

Ultimately, if sites begin to use Java Applets to achieve what they can no
longer achieve using client-side script alone, they will. And in the
constant back-and-forth battle being waged, popup blocker authors will
counter. In the end the only losers are developers, who can no longer rely
on the ability to open a new window on the browser of a person visiting
their site, and the users themselves, who no longer have as rich a GUI
experience as they could have had using multiple windows _correctly_.
 
M

Mickey Segal

Grant Wagner said:
The Google toolbar and the IE popup blocker in Windows XP SP2 on the
other hand, notice the unrequested[1] new window opening and block it.

I'm still puzzled by some of the details of blocking of showDocument:

The Microsoft blocker does not block showDocument from an applet in a Web
page (http://www.segal.org/java/pop_window3/) but does block showDocument
from an applet Frame (http://www.segal.org/java/pop_window4/).

The Google blocker puts up a yellow explosion icon when blocking
showDocument from an applet in a Web page
(http://www.segal.org/java/pop_window/) but it fails to put up the yellow
explosion icon when blocking showDocument from an applet Frame
(http://www.segal.org/java/pop_window2/).

Things get even stranger when running an applet from your local machine.
There are circumstances in which showDocument is blocked even when the
pop-up blocker is OFF; this seems to happen only with a DIGITALLY SIGNED
applet, a problem that is fixed in part by using the "Mark of the Web"
approach detailed at http://www.phdcc.com/xpsp2.htm. It seems strange that
the most restrictions would be targeted at signed code running on the local
machine, yet be fixable in a simple way.
 
A

Andrew Thompson

Thanks to both you and Mickey for further
arcane information.

I read your response some hours ago Grant,
and drafted a detailed response to the many
interesting points you made, the trouble is..
I was tripping over some details so I thought
best to 'file' it in drafts, but actually
deleted it! (rolls eyes)

In any case, I think it best I give more thought
to what you and Mickey have added to this thread,
before I return with more specific comments, so ..

"I'll get back to this soon"
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,057
Latest member
KetoBeezACVGummies

Latest Threads

Top