I'm trying to migrate a Java applet to a Java web start application. The applet was activated from a JavaScript with several parameters, some are not hard-coded (sessionId, tempFilePath):
deployJava.runApplet(attributes, parameters);
In order to migrate the applet I'm using a simple JNLP file with applet-desc tag. And from the JavaScript I call:
deployJava.launchWebStartApplication('$jnlp_path');
I just can't understand how to pass to the web start application the parameters that were created by the JavaScript.
解决方案
OK, so it turns out that using deployJava.launchWebStartApplication(...) triggers security restrictions in Chrome and IE.
What I did is kind of work around: I sent an HTTP request to my server and the server's response was a JNLP content.
On the server side, I edited the JNLP on runtime and each time I inserted the required parameters.
When the browsers receive the JNLP content they trigger the download of the required jar.
And that's it!