开发者

Execute application from web browser?

开发者 https://www.devze.com 2023-01-20 10:07 出处:网络
How can I execute a desktop application from a brow开发者_Python百科ser?. I have a web page with a button, when user click this button a simple java desktop application must run. How can I do this usi

How can I execute a desktop application from a brow开发者_Python百科ser?. I have a web page with a button, when user click this button a simple java desktop application must run. How can I do this using jsp or javascript?


Java Web Start might be your solution.

To start a Java Web Start application, you simply direct the browser to the location of the JNLP file. Basically, the browser detects that instead of simply downloading the file, it should run it in Web Start.

Most major browsers support Java Web Start. Java Web Start is cross platform (works on Mac and PC).

So, in Javascript, it's done simply like this:

window.location = "http://www.examples.com/myapp.jnlp";

You'll also need to sign your Java application, or the user will get a nasty warning.


You should take a look at the Java Web Start technology.


This would be the closest thing: Java Web Start


Managing this through Applets is another option though the underlying scheme is the same, the user needs to accept the generated certificate.

0

精彩评论

暂无评论...
验证码 换一张
取 消