Call a java applet method via javascript
===

How can I call a function when a specific event occurs in my java Applet ?

In my Javascript I has the following code, that always return a empty value.

    $(function () {
        alert(document.applets[0].returnClientId());
    });

I need to call this alert, just when a specific method is executed. To be more specific, the method called identify, that exists in my java Applet.

The identify method, exists in my Util.class, that don't extends from JApplet.
My FormMain.class extends from JApplet and I call some methods (including the identify method) from this Util.class.

Someone has some idea ?