[Zope] Passing a string to a dtml method

Steve Spicklemire steve@spvi.com
Sat, 1 Dec 2001 13:48:19 -0500


Hi Bruce,

make your email dtml method something like this:

<FORM METHOD="POST" ACTION="/Util/send">
<INPUT TYPE="HIDDEN" NAME="name" VALUE="bruce">
<INPUT TYPE="HIDDEN" NAME="domain" VALUE="EckelObjects.com">
<INPUT TYPE="HIDDEN" NAME="subject" VALUE="<dtml-var subject>">
<INPUT TYPE="SUBMIT" VALUE="Send Email to Bruce">
</FORM>

then render it as:

<dtml-var "email(_.None, _, subject='Here comes some email Bruce!')">

-steve

On Saturday, December 1, 2001, at 01:33 PM, Bruce Eckel wrote:

> I do have a question about the anti-spam solution, though. If I
> create a dtml-method, call it "email", like this:
>
> <FORM METHOD="POST" ACTION="/Util/send">
> <INPUT TYPE="HIDDEN" NAME="name" VALUE="bruce">
> <INPUT TYPE="HIDDEN" NAME="domain" VALUE="EckelObjects.com">
> <INPUT TYPE="HIDDEN" NAME="subject" VALUE="Here is the subject
> line">
> <INPUT TYPE="SUBMIT" VALUE="Send Email to Bruce">
> </FORM>
>
> is there a way to pass the 'subject' string in during a call to the
> dtml method, so that I could do something like this inside a dtml
> document or method:
>
> <dtml-var email, subject="Here is the subject line">
>
> (obviously I can't use that syntax)
>
>
> Most current information can be found at:
> http://www.mindview.net/Etc/notes.html
> ===================
> Bruce Eckel    http://www.BruceEckel.com
> Contains free electronic books: "Thinking in Java 2e" & "Thinking
> in C++ 2e"
> Please subscribe to my free newsletter -- just send any email to:
> join-eckel-oo-programming@earth.lyris.net
> My schedule can be found at:
> http://www.mindview.net/Calendar
> ===================
>
>
>
> _______________________________________________
> Zope maillist  -  Zope@zope.org
> http://lists.zope.org/mailman/listinfo/zope
> **   No cross posts or HTML encoding!  **
> (Related lists -
>  http://lists.zope.org/mailman/listinfo/zope-announce
>  http://lists.zope.org/mailman/listinfo/zope-dev )