Closed Bug 238015 Opened 21 years ago Closed 21 years ago

Java applet cannot call JavaScript function even though JavaScript and Applet share same origin

Categories

(Core Graveyard :: Java: Live Connect, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED DUPLICATE of bug 146458

People

(Reporter: sujal.shah, Unassigned)

References

()

Details

User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7a) Gecko/20040219 Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7a) Gecko/20040219 On the page listed above, you should see a message appear in the status bar div saying connected and a clock should tick every second or every other second as messages are received from the Java applet. If I serve the page from static.espn.go.com it doesnt' work in mozilla. The applet and the javascript file containing the method that the Java applet is calling (via JSObject) are both being served from the same host (caster.espn.go.com). If I serve the page from caster.espn.go.com, though, it works fine. according to the OJI page I found here: http://java.sun.com/j2se/1.3/docs/guide/plugin/security.html the browser should only check the origin of java applet and javascript. This page works in Safari and IE... You can see it working in Moz at http://caster.espn.go.com/sujal/caster/test.html . Reproducible: Always Steps to Reproduce: 1. Go to URL above 2. Watch 3. Nothing will happen (should see a clock and a message saying "Connected to ESPN RealTime") Actual Results: No change on the page. Expected Results: You should see a ticking clock (though may not be every second) and a message saying "Connected to ESPN RealTime" It seems the browser is doing an additional security check to make sure that the page origin is the same as the javascript.
This exact bug is listed as being fixed in the 1.7b release notes... so this is a duplicate.
Whiteboard: DUPEME
Thanks for the quick response. The download pages need to be updated... nothing mentions the 1.7b release on the front page, but I realize it was just released yesterday. Great work, thanks guys. Sujal
*** This bug has been marked as a duplicate of 146458 ***
Status: UNCONFIRMED → RESOLVED
Closed: 21 years ago
Resolution: --- → DUPLICATE
Whiteboard: DUPEME
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.