• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

providing email functionality using struts

 
subbu raman
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I am new to struts framework,so i thought i could just post a message on how to go about building an application using struts for sending mails.Can anybody let me know of some examples where u hav a form and then submit the data and then the content is sent a mail.Please let me know any resources or links conataining examples or any web sites.Thanks.

Regards
SUBBU
 
sunitha reghu
Ranch Hand
Posts: 937
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Of course you can. But you need java mail api. So check this http://java.sun.com/products/javamail/

and also there are lot of tutorials available in net.

Pls do a seacrh in servlets section in JR.
 
Lou Pelagalli
Ranch Hand
Posts: 150
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I don't think struts will actually send an e-mail, but you can use it to capture the data you'll need like address, subject, and message.

Once you have all that then you can use JavaMail to send the e-mail.

http://java.sun.com/products/javamail/.

LOu
 
subbu raman
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

Thanks for the reply.I have the java mail API.What i want is like some example application say which has form and when the user submits collects all data and then action class is called which in turn uses java mail API.Any sample application which puts together the entire thing using struts framework.

Kindly let me know any website which provides these examples or any other resource.Thanks.
 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Practically any Struts tutorial will show you how to handle forms with Struts. Combine the form-processing action from such a tutorial with a JavaMail tutorial and that's about it.
 
sunitha reghu
Ranch Hand
Posts: 937
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi subbu,

Check this web page and this [URL=http://forum.java.sun.com/thread.jsp?forum=33&thread=66801&start=60&range=15&hilite=false&q=]thread[/URL. I have developed a email web app. So if you have difficulty please pm me and i will
send the source code.



Originally posted by subbu raman:
Hi

Thanks for the reply.I have the java mail API.What i want is like some example application say which has form and when the user submits collects all data and then action class is called which in turn uses java mail API.Any sample application which puts together the entire thing using struts framework.

Kindly let me know any website which provides these examples or any other resource.Thanks.


]
 
somkiat puisungnoen
Ranch Hand
Posts: 1312
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In my work, i create mail helper class for send mail / send mail with attachment which use java mail API
 
subbu raman
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Sunitha,

Thanks for the reply i found it useful.Have u developed your webapp for sendign mail using struts or normal MVC architecture.Kindly send me the source code if u have developed a webapp using struts.Thanks a lot.
 
subbu raman
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Sunitha

U can send me the source code to rama_19_77@yahoo.com.Thanks.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic