Prentice Hall and Sun Microsystems. Personal use only; do not redistribute.
A.17 Using Applets As Servlet Front Ends
547
File Upload Controls
Usual form:
(no end tag)
Attributes:
NAME
(required),
VALUE
(ignored),
SIZE
,
MAXLENGTH
,
ACCEPT
,
ONCHANGE
,
ONSELECT
,
ONFOCUS
,
ONBLUR
(nonstandard)
Use an
ENCTYPE
of
multipart/form data
in the
FORM
declaration.
Server Side Image Maps
Usual form:
(no end tag)
Attributes:
NAME
(required),
SRC
,
ALIGN
You can also provide an
ISMAP
attribute to a standard
IMG
element that
is inside an
element.
Hidden Fields
Usual form:
(no end tag)
Attributes:
NAME
(required),
VALUE
Internet Explorer Features
FIELDSET (with LEGEND): groups controls
TABINDEX: controls tabbing order
Both capabilities are part of HTML 4.0 spec; neither is supported by
Netscape 4.
A.17 Using Applets As Servlet Front Ends
Sending Data with GET and Displaying the
Resultant Page
String someData =
name1 + "=" + URLEncoder.encode(val1) + "&" +
name2 + "=" + URLEncoder.encode(val2) + "&" +
...
nameN + "=" + URLEncoder.encode(valN);
try {
URL programURL = new URL(baseURL + "?" + someData);
getAppletContext().showDocument(programURL);
} catch(MalformedURLException mue) { ... }
Second edition of this book: www.coreservlets.com; Sequel: www.moreservlets.com.
Servlet and JSP training courses by book's author: courses.coreservlets.com.
footer
Our partners:
PHP: Hypertext Preprocessor Best Web Hosting
Java Web Hosting
Jsp Web Hosting
Cheapest Web Hosting
Visionwebhosting.net Business web hosting division of Web
Design Plus. All rights reserved