cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "julien bloit" <Julien.Bl...@ircam.fr>
Subject Re: sendmail:attachment dynamic parameter?
Date Mon, 15 Mar 2004 14:45:02 GMT
Thanks, it works! Here's how, if it helps anyone else :

<xsp:logic>
     String attach_url = "cocoon:/recap_cmd/";
     attach_url = attach_url.concat(<util:get-sitemap-parameter
name="cmd_id"/>);
</xsp:logic>

<mail:send-mail>
       <mail:charset>ISO-8859-1</mail:charset>
       <mail:smtphost><xsp:expr>smtphost</xsp:expr></mail:smtphost>
       <mail:from>dvd@ircam.fr</mail:from>
       <mail:to><xsp:expr>email</xsp:expr></mail:to>
       <mail:subject>DVD a la carte : Votre commande</mail:subject>
       <mail:body><xsp:expr>mailBody</xsp:expr></mail:body>
       <mail:attachment mime-type="text/xml" name="commande.xml">
            <mail:param
name="url"><xsp:expr>attach_url</xsp:expr></mail:param>
        </mail:attachment>
</mail:send-mail>

Julien


----- Original Message ----- 
From: <robby.pelssers@vodafone.com>
To: <users@cocoon.apache.org>
Sent: Monday, March 15, 2004 3:32 PM
Subject: RE: sendmail:attachment dynamic parameter?


> i don't know if it works, but try this out
>
>        <mail:attachment mime-type="text/xml" name="commande.xml">
>          <mail:param>
>            <xsp:attribute
> name="url"><xsp:expr>Urlstring<xsp:expr></xsp:attribute>
>          </mail:param>
>        </mail:attachment>
>
> -----Original Message-----
> From: julien bloit [mailto:Julien.Bloit@ircam.fr]
> Sent: 15mm2004 15:29
> To: users@cocoon.apache.org
> Subject: sendmail:attachment dynamic parameter?
>
>
> Hi,
>
> I use cocoon 2.1.3 and having a little trouble to send mail with dynamic
> content, using the sendmail logicsheet.
> Here's an xsp snippet that works :
>
> <mail:send-mail>
>        <mail:charset>ISO-8859-1</mail:charset>
>        <mail:smtphost><xsp:expr>smtphost</xsp:expr></mail:smtphost>
>        <mail:from>dvd@ircam.fr</mail:from>
>        <mail:to><xsp:expr>email</xsp:expr></mail:to>
>        <mail:subject>shop : your command</mail:subject>
>        <mail:body><xsp:expr>mailBody</xsp:expr></mail:body>
>        <mail:attachment mime-type="text/xml" name="commande.xml">
>             <mail:param name="url">cocoon:/recap_cmd/24</mail:param>
>        </mail:attachment>
>       </mail:send-mail>
>
> but I need the attachment 'url' parameter to be dynamic , i.e. like this :
>
> <mail:param
> name="url">cocoon:/recap_cmd/<xsp:expr><util:get-sitemap-parameter
> name="cmd_id"/></xsp:expr></mail:param>
>
> which doesn't work (although pulling in the sitemap parameter works
> elsewhere in the xsp).
>
> Has someone got any clue on how I could fix this?
>
> Thanks a lot,
> Julien
>
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
>
>


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


Mime
View raw message