Switch to full style
Project under GPL source codes are posted here
Post a reply

add applet to jsp

Sun Jan 11, 2009 1:07 am

* Project Name:   Add applet to jsp pluggin
* Programmer:   not known
* Type:   Plugin
* Technology:  Java
* IDE:   NONE
* Description:   Contain a Plugin to add your java applet to your jsp .There is a jar file and small applet example added .

Apple code
java code
import java.awt.*;
import java.awt.event.*;
import java.applet.*;
import javax.swing.*;

public class Applet1 extends JApplet {

boolean isStandalone = false;
TextArea textArea1 = new TextArea();
GridLayout gridLayout1 = new GridLayout(1,2);

public String getParameter(String key, String def) {

return isStandalone ? System.getProperty(key, def) :
(getParameter(key) != null ? getParameter(key) : def);
}

public void init() {
try {
textArea1.setText("");
this.setSize(new Dimension(400, 296));
this.getContentPane().setLayout(gridLayout1);
this.getContentPane().add(textArea1, null);
}
catch(Exception e) {
e.printStackTrace();
}
}

//Get Applet information
public String getAppletInfo() {

return "Applet Information";
}

//Get parameter info
public String[][] getParameterInfo() {
return null;
}
}

JSP code
java code
<table>
<tr>
<td>
<jsp:plugin type="applet" code="Applet1.class"
codebase="/purejsp/TestApplet"
width="400"
height="300">
</jsp:plugin>
</td>
</tr>
</table>



Attachments
UseAppletInJsp.zip
applet within jsp
(85.35 KiB) Downloaded 1307 times

Re: add applet to jsp

Sun Jan 20, 2013 9:04 pm

updated.

Post a reply
  Related Posts  to : add applet to jsp
 load class to applet- load frame class to applet     -  
 First Applet     -  
 JFrame on applet     -  
 Java applet     -  
 applet in netbeans     -  
 Snake applet     -  
 Ball Sticker{Applet}     -  
 Applet File Permission     -  
 how to connect applet with excel     -  
 Ball sticker applet     -  

Topic Tags

Servlets/JSP, Java Applet