[Zope] Re: <dtml-var reason>

Maik Jablonski maik.jablonski@uni-bielefeld.de
Tue, 01 Apr 2003 10:04:55 +0200


Marie Robichon wrote:
> I would like to send an email to all the users in my EasyPulbisher 
> acl_users folder, however if the email address is wrong it breaks out of 
> the loop.
> 
 > I have tried putting a <dtml-try> and <dtml-except> in the code but
 > nonetheless the loop breaks and only the users up to the user where
 > the error occurs gets my mail.

Hi Marie,

did you try it this way?

<dtml-in "acl_users.getUserNames()">
<dtml-try>
<dtml-sendmail mailhost="EasyMailService">
To: <dtml-var "acl_users.getUser(_['sequence-item']).ec_email">
From: <dtml-var "AUTHENTICATED_USER.getUserName()">@esrf.fr

<dtml-var message>
</dtml-sendmail>
<dtml-except>
Could not mail to ...
</dtml-try>
</dtml-in>

Cheers, Maik