dcsimg
how to javamail works with sendmail(SMTP) on linux ?
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Narayan_Joshi
Posted On:   Monday, August 5, 2002 07:22 AM

Dear Friends,
Your urgent help required.
I have a linux server on which a sendmail program is already running to send mails. (sendmail works on SMTP protocol).
So, now i want to make a javamail program in the existing environment. How can i send mail through a browser based applet with help of javamail to the sendmail program so that finally sendmail will manage to send my mail to the final recipient of the message ?

plz. help me.
Thanks

Re: how to javamail works with sendmail(SMTP) on linux ?

Posted By:   Lunkwill_Vroomfondel  
Posted On:   Monday, August 5, 2002 08:38 AM

if sendmail is running on your server (as daemon), it is usually configured to accept connections on port 25 (the well-known-smtp-port).



then do something like this:


Properties props=System.getProperties(); props.put("mail.smtp.host","yourservernameoraddresshere");



and create a session from that.



you shouldnt use an applet - better use an application or develop a simple servlet or jsp for it.
About | Sitemap | Contact