//
Properties props = System.getProperties();
props.put("mail.smtp.host", getMailSMTPServer());
// Get a Session object
javax.mail.Session mailSession =
javax.mail.Session.getDefaultInstance(props, null);
where getMailSMTPServer() method is something like
if (this.getServletContext().getInitParameter("mailSMTPServer") !=
null)
return
this.getServletContext().getInitParameter("mailSMTPServer");
else
return ""; //default smt server!!!
and mailSMTPServer is a properties in web.xml file o fyour webapp.
andrea
At 11.06 18/01/2001 +0100, you wrote:
>Hello Vittorio!!!!!!!!!
>
>Why do you want to set SMTP server properties in the javamail package????
>Isn't more simple to set server properties in the servlet (read it from a
>configuration text file)????
>
>p.s.: di dove sei????
>
>Robuschi Roberto -------------------- Delfi srl
>P.za Ravenet 1/b - 43100 PARMA
>Tel. 0521/932474 Fax 0521/989045
>[EMAIL PROTECTED] --- http://www.delfi.it
>
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, email: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]