Sunday, September 28, 2014

How to Know if Your Server Has JavaMail

Instructions

    1

    Open the JSP editor from your Windows program menu. Open your current project and create a new file. Name the file "test.jsp" so you can quickly find it and delete it from the project after you finish testing for JavaMail.

    2

    Add the JavaMail library to the top of your file. The following shows you how to add an include file with the JavaMail server library:

    <%@ page import="sun.net.smtp.SmtpClient" %>

    3

    Save the file and click "Run" in the JSP editor to run the file on the server and in your default browser. If the page returns "Error on Line 1," you know that the server doesn't contain the JavaMail server files. If no error is presented, you know your server contains JavaMail.



No comments:

Post a Comment