Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

make a java application downloadable on the web

 
novice help
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi there,
My boss want to put a java application (6 classes) on his homepage and can be downloaded free, anyone know how to do it or pointer to the source? Thanks!
 
Jos� Alberto Mu�iz Navarro
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You mean something like pack them in a JAR and put them in a server, along with a webpage that links to it? Or do you mean something like transform them into an Applet?
 
novice help
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi there,
Thanks for your reply. I think it's the first one you mentioned. I really appreciate it if you can give some more detail although I already learned something useful from your short answer.
 
Jos� Alberto Mu�iz Navarro
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well uhm... first of all you'll need a web server. Maybe your company has one server of its own or you can hire some.

Next you'll have to create an html from where the users will be able to click and download the classes. (I assume you'll want to download the .class not the .java, because otherwise those who download it would have to compile them).



Then you save that document as an html and place it in the server. In the same directory, you have to include the classes (class1.class, class2.class, class3.class, etc).

You can also create a JAR out of all the classes and then upload it as only one file instead of the others. However, that would depend on whether you want that to happen or not . To create a JAR, you have to use the jar command

 
novice help
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you very much, I will try these one by one!
 
Gregg Bolinger
GenRocket Founder
Ranch Hand
Posts: 15302
6
Chrome IntelliJ IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
novice help,

Welcome to Javaranch. We don't have too many rules around here but we do have a Naming Policy. Please adjust your display name.

Also, this sounds like a good question for the HTML forum. So I'll move it there even though you already got an answer.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic