here's my code for mailing..u need to setup pop access in yahoo under web access and pop forwarding...
 
  Properties props = new Properties();
  Session ses = Session.getDefaultInstance(props,null);
  Store store = ses.getStore("pop3");
  store.connect("pop.mail.yahoo.com","yahooID","password");
  MimeMessage message = new MimeMessage(ses);
  Address to = new InternetAddress("
[EMAIL PROTECTED]");
  Address from = new InternetAddress("
[EMAIL PROTECTED]");
  String person = req.getParameter("first") + " " + req.getParameter("last");
  Address replyTo = new InternetAddress(req.getParameter("replyto"), person);
  Address[] replyArr = {replyTo};
  Address[] toArr = {to};
  message.setFrom(from);
  message.addRecipients(Message.RecipientType.TO, toArr);
  message.setReplyTo(replyArr);
  message.setSubject("Feedback");
  message.setText(req.getParameter("comments"));
  message.setSentDate(new Date());
  message.saveChanges();
  Transport.send(message);
  store.close();
 
for java stuf..goto http://pallav.cjb.net
 

Reply via email to