I just complied all my java programs, which consists of 4 classes and everything's working fine. I have the GUI, client, server, and the action listeners and an image all in the same folder. I just don't know how to put my local java application that I debugged and tested in JGrasp software onto my webpage. I looked around and I read you need to make a jar file and compress all of them, but I don't know how to do that, neither creating an applet. I tried the most simple way of doing it by attempting to convert the .java file "SMTPServer", the class used to run the application, and convert that into a JNLP file and it brought up a Java WebStart Application, but was unable to run it. This is my first time trying to port it to the webpage. How do I do this?
Asked
Active
Viewed 1,365 times
0
-
what is the server you are using? – Crickcoder Oct 06 '13 at 22:44
-
its all local. I tested it using 127.0.0.1 – TheAmazingKnight Oct 06 '13 at 22:58
-
1I mean did you use a local server like tomcat,jboss etc. – Crickcoder Oct 06 '13 at 23:59
1 Answers
1
This basic example is a hybrid. The JAR contains a single class. The JAR can be deployed as either an applet or application. You can build a JAR containing your compiled class files in JGrasp
as shown here.
<resources>
<j2se version="1.6+" href="http://java.sun.com/products/autodl/j2se"/>
<jar href="YourApplication.jar"/>
</resources>
-
1
-
1
-
Very pretty. :) It can even help spot malformed HTML/JNLP/XML by sight. I frequently use it for just that when editing questions. ;) – Andrew Thompson Oct 08 '13 at 01:43