Web Hosting Directory | Web Hosting Resources | Webmaster Resources | Domain Tools | Search Engine Marketing | Forums
  Signup
Today: 228   Yesterday: 494   Max: 1,872   Total: 364,050   Current Users : 13 (Member 0) 
DOMAIN TOOLS

WEBMASTER TOOLS

RELATED ARTICLES

SUBMIT AN ARTICLE

Write for us and get publicity, link to your website, and best of all get paid. Please visit our writers page for details.


LINK TO US

Link to us and earn points for each visitor you bring to us. Please visit our link partner page for details.

 

Applets

Contents

<APPLET ...>
<APP ...>
<PARAM ...> Parameter
<APPLET ...> next page
An applet is a miniature program that you embed right into your web page. Applets themselves are not written in HTML... they are separate programs written in a language called Java. Placing an applet in your page is like putting a little window in the middle of the page, and one of these Java programs is running in that window. You don't need a special web server to put applets in your web page... you can use the same server that serves your web pages.

If you are familiar with putting pictures in your web page, you will probably find that putting applets in your page is very similar (though not identical). The applet program (called a "class" file) is a separate file from your HTML file. You use the tags <APPLET ...> and <PARAM ...> to place the applet into your web page, much the same way you use <IMG ...> to place a picture in your page .

<APPLET ...> calls the applet, <PARAM ...> gives details on how to run the applet (called parameters). Anything else inside the <APPLET ...> tag is ignored, so that's where you put information for browsers that don't understand applets.

For example, this HTML code calls an applet called "MyApplet", and tells MyApplet to display the words "Hi There":

this code produces this
<APPLET CODE="MyApplet.class" WIDTH=200 HEIGHT=50>
     <PARAM NAME=TEXT VALUE="Hi There">
     <P>Hi There!<P>
</APPLET>

Hi There!

Here's what each piece means:

<APPLET CODE="MyApplet.class" WIDTH=200 HEIGHT=50>
Run the applet "MyApplet.class". The area for the applet should be 200 x 50.

<PARAM NAME=TEXT VALUE="Hi There">
Pass this information to the applet: the text (NAME=TEXT) should be "Hi There" (VALUE="Hi There")

<P>Hi There<P>
This is what is displayed in browsers that don't understand applets.

</APPLET>
End of the code to run this applet.

The HTML for putting applets into a page is very standardized: you only need to learn a few tags and attributes. However, each applet has its own set of parameters which are used to make it run. Since every applet is different, you need to know what parameters to use for each applet. For example, the MyApplet applet requires you to use the TEXT parameter, but that's just MyApplet; most applets have no such parameter. To learn how to use each applet, consult the documentation for that applet.


Copyright 1997-2002 Idocs, Inc. Written by Miko Sullivan.

 
 
What is your major source of website traffic?
 
 
 
 
 
 

ADVERTISEMENT

 
Cheap Web HostingBudget Web HostingEcommerce Web Hosting
Link to UsLink ExchangeAdvertisePrivacy PolicyTerms Of ServiceAbout UsContact UsSitemap
Copyright © 2006 - 2008 Broadband Media, Inc. All rights reserved.