Hello,

I'm new to Zope, Python and DTML and could therefore use some help.
I have a page in which I want to pass an argument to a new DTML method when clicking a link. The relevant snippet is:

<a href="/contact?name_id:int=<dtml-var name_id>">Contact</a>

So, when you click on "Contact" you should get a new window. The variable "name_id" is previously established on the page and shows up correctly when the pointer hovers over the link, i.e. the status bar at the bottom of the browser reads:

http://server.website.edu/contact?name_id:int=3

However, the DTML code for the new page doesn't seem to find this value and returns a message telling me that no name was found. Because I am stuck, here is the virtual entirety of the code:

<dtml-if "not REQUEST.has_key('name_id')">
No name was found. Please specify a name.
<dtml-else>
Thank you! The request has been made.
</dtml-if>

How can I get this page to recognize the passed argument so I can call a method with it?

I have seen similar threads here on this topic but was unable to find a solution from reading them. I am also baffled by the fact that in large part I'm reusing the same code that seems to work perfectly in the same format on other pages (which I didn't write). This is probably something very simple, but I would really appreciate a hand.

Thanks in advance,

Santani


_______________________________________________
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - http://mail.zope.org/mailman/listinfo/zope-announce
http://mail.zope.org/mailman/listinfo/zope-dev )

Reply via email to