Visit Gopalan Suresh Raj's Web Cornucopia...

Developing the E-Mail Sender JSP Page
Gopalan Suresh Raj

Note
To work with any of these samples, you will need the following:
.........................................JDK 1.1.7 or higher

To work with the Servlets and JSP, you will need
.........................................
JSWDK 1.0.1 or higher

To work with the Java Mail API, you will need
.........................................
JavaMail 1.1.3 or higher
.........................................
Java Activation Framework 1.0.1 or higher
.........................................
POP3 Provider 1.1.1 or higher

1. Develop the EmailSend.jsp file

Design a Page called EmailSend.jsp as shown.

The JSP Model 2 Architecture
(Model-View-Controller Based)

Figure shows what we are trying to ultimately accomplish in these pages here.

EmailSend.jsp
<html>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=ISO-8859-1">
<head>
<title>Gopalan Suresh Raj's Email Servlet</title>
</head>

<body bgcolor="#FFFFFF">

<p align="center"><font color="#000080" size="5" face="Arial">
Gopalan Suresh Raj's Email Servlet</font></p>
<div align="center"><center>

<form name="emailSendForm" action="/examples/servlet/EmailSendServlet" method="POST">
<table border="0" cellpadding="2" width="90%">
    <tr>
        <td width="10%"><font size="3" face="Tahoma"><strong>From</strong></font></td>
        <td width="50%"><font size="2" face="Tahoma">
        <input type="text" size="80" name="FromBox"></font></td>
    </tr>
    <tr>
        <td width="10%"><font size="3" face="Tahoma"><strong>To</strong></font></td>
        <td width="50%"><font size="2" face="Tahoma">
        <input type="text" size="80" name="ToBox"></font></td>
    </tr>
    <tr>
        <td width="10%"><font size="3" face="Tahoma"><strong>CC</strong></font></td>
        <td width="50%"><font size="2" face="Tahoma">
        <input type="text" size="80" name="CcBox"></font></td>
    </tr>
    <tr>
        <td width="10%"><font size="3" face="Tahoma"><strong>BCC</strong></font></td>
        <td width="50%"><font size="2" face="Tahoma">
        <input type="text" size="80" name="BccBox"></font></td>
    </tr>
    <tr>
        <td width="10%"><font size="3" face="Tahoma"><strong>Subject</strong></font></td>
        <td width="50%"><font size="2" face="Tahoma">
        <input type="text" size="80" name="SubjectBox"></font></td>
    </tr>
    <tr>
        <td colspan="2" width="100%"><p align="center"><font></td>
        size="2" face="Tahoma"><textarea name="BodyBox" rows="15"
        cols="80"></textarea></font></p>
        </td>
    </tr>
</table>
</center></div>

    <p align="center">
    <input type="submit" name="SubmitButton"
    value="Send Mail"></p>
</form>
</body>
</html>


2. Create a Directory called "EmailHandler" on the "jswdk-1.0.1\examples\jsp\" directory and Copy this JSP page there.

click here to go to
My JSP/Servlets HomePage...

About the Author...
Gopalan Suresh Raj is a Software Architect, Developer and an active Author. He is contributing author to a couple of books "Enterprise Java Computing-Applications and Architecture" and "The Awesome Power of JavaBeans". His expertise spans enterprise component architectures and distributed object computing. Visit him at his Web Cornucopia© site (http://www.execpc.com/~gopalan) or mail him at gopalan@execpc.com.

Go to the Component Engineering Cornucopia page

This site was developed and is maintained by Gopalan Suresh Raj

This page has been visited times since September 21,1998.

Last Updated : Dec 19, '98

If you have any questions, comments, or problems regarding this site, please write to me I would love to hear from you.


Copyright (c) 1997-2000, Gopalan Suresh Raj - All rights reserved. Terms of use.

All products and companies mentioned at this site are trademarks of their respective owners.