Changes for page Sending Emails
Last modified by Pascal Robert on 2012/08/12 21:24
From version 14.1
edited by Pascal Robert
on 2012/08/12 21:24
on 2012/08/12 21:24
Change comment:
There is no comment for this version
To version 11.1
edited by David Avendasora
on 2011/05/03 04:38
on 2011/05/03 04:38
Change comment:
There is no comment for this version
Summary
-
Page properties (3 modified, 0 added, 0 removed)
Details
- Page properties
-
- Title
-
... ... @@ -1,1 +1,1 @@ 1 -Sending Emails 1 +Development-Sending Emails - Author
-
... ... @@ -1,1 +1,1 @@ 1 -XWiki. probert1 +XWiki.avendasora - Content
-
... ... @@ -1,17 +1,17 @@ 1 1 == Overview == 2 2 3 -Sending emails is a very common requirement in a web application. There are several methods you can choose from, each with varying levels of complexity and power. 3 +Sending emails is a very common requirement in a web application. There are several methods you can choose from, each with varying levels of complexity and power. 4 4 5 -== ERJavaMail ==5 +== JavaMail == 6 6 7 - ERJavaMailispartof ProjectWonderand providesan API forsendingcomponent-basedemails.ERJavaMail alsoestheJavaMail API'sunderneath,butitincludes thejars insideitsframework,so you don't needtomanuallyinstallJavaMail touseit.Because it does nothave anyexternaldependenciesonotherProjectWonderframeworks,youcan useit withoutbringinginnyotherProject Wonderframeworks.Formore informationonERJavaMail,seethe [[ERJavaMail>>doc:ERJavaMailFramework]]page.7 +[[JavaMail>>http://java.sun.com/products/javamail/]] is Sun's API definition and open-source reference implementation of various methods of sending and receiving mail. All of the other WO mail-sending techniques are based on JavaMail, but you can choose to use it directly rather than use the higher level API's described below. If you would like to use JavaMail on your own, you will need to download and install the following jars and put them into your WOA's classpath: 8 8 9 -== JavaMail == 9 +* [[JavaMail>>http://java.sun.com/products/javamail/downloads/index.html]] 10 +* [[Java Activation Framework>>http://java.sun.com/products/javabeans/jaf/downloads/index.html]] 10 10 11 - [[JavaMail>>url:http://java.sun.com/products/javamail/||shape="rect"]]is Sun's API definition and open-source reference implementation of various methods of sending and receiving mail. All of the other WO mail-sending techniques are based onJavaMail,but you can choose to use it directly rather than use the higher level API's described below. If you would like to use JavaMail on your own, you will need to download and install the following jars and put them into your WOA's classpath:12 +== ERJavaMail == 12 12 13 -* [[JavaMail>>url:http://java.sun.com/products/javamail/downloads/index.html||shape="rect"]] 14 -* [[Java Activation Framework>>url:http://java.sun.com/products/javabeans/jaf/downloads/index.html||shape="rect"]] 14 +ERJavaMail is part of Project Wonder and provides an API for sending component-based emails. ERJavaMail also uses the JavaMail API's underneath, but it includes the jars inside its framework, so you don't need to manually install JavaMail to use it. Because it does not have any external dependencies on other Project Wonder frameworks, you can use it without bringing in any other Project Wonder frameworks. For more information on ERJavaMail, see the [[ERJavaMail>>Project WONDER-Frameworks-ERJavaMail]] page. 15 15 16 16 == WOMailDelivery == 17 17 ... ... @@ -19,13 +19,13 @@ 19 19 You really should use ERJavaMail, WOMailDelivery is not as flexible as ERJavaMail is. 20 20 {{/warning}} 21 21 22 -Built into WebObjects is the WOMailDelivery class. It provides a very simple API for sending mails, but lacks the power of Project Wonder's version. To use WOMailDelivery, you will need to set your SMTP server in one of the following ways: 22 +Built into WebObjects is the WOMailDelivery class. It provides a very simple API for sending mails, but lacks the power of Project Wonder's version. To use WOMailDelivery, you will need to set your SMTP server in one of the following ways: 23 23 24 -* Add -DWOSMTPHost=smtp.yourmailserver as a launch parameter24 +* Add DWOSMTPHost=smtp.yourmailserver as a launch parameter 25 25 * Set WOSMTPHost=smtp.yourmailserver.com in your Properties file 26 26 * Hardcode it with WOApplication.application().setSMTPHost("smtp.yourmailserver.com"); 27 27 28 -Refer to the [[WOMailDelivery API>> url:http://wocommunity.org/documents/javadoc/WebObjects/5.4.2/com/webobjects/appserver/WOMailDelivery.html||shape="rect"]] for more information, but to simply send an email, you can use the following command:28 +Refer to the [[WOMailDelivery API>>http://webobjects.mdimension.com/javadoc/WebObjects/5.4.2/com/webobjects/appserver/WOMailDelivery.html]] for more information, but to simply send an email, you can use the following command: 29 29 30 30 {{code}} 31 31 ... ... @@ -39,4 +39,4 @@ 39 39 40 40 {{/code}} 41 41 42 -By default, WOMailDelivery with use Sun's old SMTP implementation. However, if you install JavaMail (as described above) into your WOA or /Library/WebObjects/Extensions, WOMailDelivery will use it instead. 42 +By default, WOMailDelivery with use Sun's old SMTP implementation. However, if you install JavaMail (as described above) into your WOA or /Library/WebObjects/Extensions, WOMailDelivery will use it instead.