HOW TO GET .jnlp Java apps to run from Firefox in Gnome
Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
HOW TO GET .jnlp Java apps to run from Firefox in Gnome
Following my creedo of "Every time I spend 45 minutes screwing with something and then finally figure it out", I want to put my solution here so that it'll be here for other people (and me, when I forget) later to find via search.
PROBLEM:
Java apps using the JNLP (java network launcher protocol, or whatever) don't work.
You click on "run app" on a webpage, and it pops up a "What do I open this with?!?". The default answer is either "firefox" or "mozilla", but when you click OK, it just goes ahead and pops up another browser, and then says "What do I open this with?!?" ad infinitum.
You *KNOW* you've got java installed. Hell, you installed JRE, JDK, and then just to be on the safe side, the entire billion-megabyte J2EE suite.
You've symlinked the libjavaplugin.so thingie from BOTH your firefox install's plugins directory AND your ~/{.mozilla|.firefox}/plugins/ directory.
You've tried telling firefox to start the application with the JRE/bin/java app.
You've tried to change the mime type thingie for application/java-jnlp-network-launcher or whatever, but you can't for the life of you figure out how to edit the "download" actions. Downloading some obscure FF extention from romania doesn't solve it, either.
Still doesn't work. You're about to commit sepuku.
SOLUTION:
Next time you come across a .jnlp, click "Save to disk" and save it to desktop or ~ or whatever.
Open a gnome finder window thingie, right click the jnlp file, and select whatever the equivilant of "Open With..." is. Navigate to your javaws application. This is going to be under your JRE folder, which could be any number of places. It could be anywhere from /usr/java/jdk/jre/bin/javaws or /opt/SUNWappserver/jdk/jre/bin/javaws or anywhere. When in doubt, and desperate, try which javaws. If it returns a Sun java, cool, use that one. If it returns nothing or one of the silly GNU java-alternatives in /etc/alternatives/blah (track down the symlinks), then do a cd / ; find | grep javaws or whatever your pefered method of thrashing your hard drive for 5 minutes is.
You should be good. Gnome now knows what application to use to open the thing, so when firefox doesn't know, it'll ask gnome, and gnome will know. You can even click "do this from now on" if you're confident the next time firefox asks.
You don't need to save the .jnlp, you just need to select "Other Application" when that dialog box pops up, then navigate to javaws, and click on OK. There is also a checkbox that lets you permanently set this. Sticking within Firefox makes this less dependent on Gnome.
Heh, that's funny! I had (of course, 4 years later) forgotten that I'd written this post. In fact, when I wrote it, Android (much less chrome) didn't exist.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.