I know that there have been several threads on this list concerning the way to pass arguments to a DTMLMethod. I've done what I think is correct, yet my result is less than pleasing. Here's what I have and what I'm doing. Hopefully someone will identify what I'm doing wrong. In my web sites root folder (aka /Foo), I have a DTMLMethod named "siteRoot". It simply answers "Foo". In a subfolder of Foo, I have a method named "linkFor". The code for this method looks like this: /<dtml-var siteRoot>/SomePage?option=<dtml-var optionValue> In the same folder that contains the "linkFor" method, I have another method which wants to use the result of the "linkFor" method. In this method there is a line which looks like this: <a href="<dtml-var "linkFor(_, _.None, optionValue='some value')">">Some Text</a> When this code gets executed, I get a "KeyError" on "siteRoot". For some reason, when my linkFor method executes, it can't see the siteRoot method, even though the method exists in the parent folder. What am I doing wrong? Why can't linkFor see siteRoot? Thanks. James W. Howe mailto:jwh@allencreek.com Allen Creek Software, Inc. pgpkey: http://ic.net/~jwh/pgpkey.html Ann Arbor, MI 48103
On Thu, 9 Mar 2000, James W. Howe wrote:
<a href="<dtml-var "linkFor(_, _.None, optionValue='some value')">">Some Text</a> ^^^^^^^^^ other way round: (_.None, _, ...)
Oleg. ---- Oleg Broytmann Foundation for Effective Policies phd@phd.russ.ru Programmers don't die, they just GOSUB without RETURN.
participants (2)
-
James W. Howe -
Oleg Broytmann