[Zope] sendmail / python list parameter -> DTML method

Lee lee.reilly@ntlworld.com
Thu, 18 Jan 2001 08:28:49 +0000


Thanks again Dieter! Everything's working just about perfect but can I ask
you one quick question?

When a form is submitted the current REQUEST object's form data is cleared
and repopulated using the new form input parameters, yeah? Is it possible
to *not* clear it?

Why do I want to do this? Well, I've used <dtml-call
"REQUEST.set('recipients',[])"> to help me display an email message in a
form, which when submitted will be sent using <sendmail>.

>Email message displayed here<

<form action="method4">
<input type="hidden" name="subject" value="<dtml-var subject>">
<input type="hidden" name="sender" value="<dtml-var sender>">
<input type="hidden" name="senderEmail" value="<dtml-var senderEmail>">
<input type="hidden" name="message" value=<dtml-var message>"">
*** some code here to pass the recipient *list* as a parameter / stop the
REQUEST object from being cleared ***
*** e.g <input type="hidden" name="recipients" value=<dtml-var
recipients>"> or <input type="hidden" name="recipients" value=<dtml-var
recipients>:list"> produces the wrong results... ***
<input type="submit">
</form>

If the list holds ['ltyler', 'lreilly'] then displaying it in the next
method using <dtml-var recipients> produces ['ltyler', (i.e. the first
element). Do you know how can I get round this?

I've CC's this to the newsgroup in case someone there can help.

Thanks very much,

Lee

Dieter Maurer wrote:

> Lee writes:
>  > <dtml-call "REQUEST.set(recipients,[])">
>  <dtml-call "REQUEST.set('recipients',[])">
>
> You have to enclose "recipients" in '...'.
> Otherwise, it is interpreted as a variable, which does not (yet) exist.
>
> Dieter

--
Lee Reilly
mailto:lee.reilly@ntlworld.com

ø¤º°`°º¤ø,,,,ø¤º°`°º¤ø,,,,ø¤º°`°º¤ø,,,,ø¤º°`°º¤ø,,,,

HAVE SKILLS; WILL TRAVEL.

I'm currently looking for an internship in the USA
in the field of web development. Ideally, I'm looking
for a placement for 3 to 18 months. Can you help?

More details, my resume, etc. @
http://homepages.strath.ac.uk/~aeu97172/

</shameless plug>