You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Joose Vettenranta <jo...@iki.fi> on 2003/10/03 08:57:23 UTC

XSP and sending 100 emails

Hi,

can sendmail XSP be used to send 100 emails in a loop? I have like 100
recipient and for all of them I have to create different email (just CC:
won't do). So, is it possible somehow do like this:

while (morerecipients) {
 next.recipient;
 <generate message>;
 <sendmessage to recipient>
}

- Joose

-- 
Joose Vettenranta <jo...@iki.fi>  GSM: 044 561 0270
* Always remember that you are unique.
                          Just like everyone else.*

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


RE: XSP and sending 100 emails

Posted by Joose Vettenranta <jo...@iki.fi>.
On pe, 2003-10-03 at 10:28, Andrea Scolari wrote:
> Hi Joose.
> 
> > can sendmail XSP be used to send 100 emails in a loop?
> Yes, you can do like you've written:

Good. Then I was not able to find info how to create mime-type related
to the content? I mean, if I create HTML-message and use <img
src="cid:name" /> in the source, then create attachment with name cid.
So how to create that attachment related?

sendmail:body seems to be only for text/plain and <sendmail:attachment
has no way of saying it's related to the content or alternative
(creating text/html and text/plain messages using alternative
bodycontent).

I have created some sort of a transformer which get's it's input from
XML but currently it's kinda slow. That transformer is able to create
alternative and related messages and use cocoon:/ type urls for content.
Perhaps I should publish the source and let people see it and help me to
finnish it.

- Joose
-- 
Joose Vettenranta <jo...@iki.fi>  GSM: 044 561 0270
* Always remember that you are unique.
                          Just like everyone else.*

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


RE: XSP and sending 100 emails

Posted by Andrea Scolari <a....@ticino.com>.
Hi Joose.

> can sendmail XSP be used to send 100 emails in a loop?

Yes, you can do like you've written:

while (morerecipients) {
	<mail:send-mail>
	  <mail:charset>ISO-8859-1</mail:charset>
	  <mail:smtphost>mail.xxx.ch</mail:smtphost>
	  <mail:from>xxx@xxx.ch</mail:from>
	  <mail:to><xsp:expr>email</xsp:expr></mail:to>
        <mail:subject><xsp:expr>subject</xsp:expr></mail:subject>
	  <mail:body><xsp:expr>text</xsp:expr></mail:body>
  	</mail:send-mail>
}

Best regards,


Andrea Scolari


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org