dtml-let vs. REQUEST.set
I have a Z SQL Method I'm trying to call with user_id set to the name of whomever had been authenticated via Zope's authentication methods. If I use dtml-let to assign a value to the user_id parameter, I get an error. But if I use REQUEST.set to assign the value, it seems to work fine. I.e., if I try to build the user_id value with this code: <dtml-let user_id="REQUEST.AUTHENTICATED_USER.getUserName()"> I get this error: Error Type: Bad Request Error Value: ['user_id'] However, if I use this code to assign the value to user_id: <dtml-call "REQUEST.set( 'user_id', REQUEST.AUTHENTICATED_USER.getUserName())"> Everything seems to work fine. So, I've got a working version in the latter, but I don't understand why it works and the former doesn't. Can anyone lend any insight? Sean
When calling a Z SQL Method (with the user_id parameter)... On Mon, 20 Aug 2001, McMains, Sean wrote: <!-- doesn't work -->
<dtml-let user_id="REQUEST.AUTHENTICATED_USER.getUserName()">
<!-- works -->
<dtml-call "REQUEST.set( 'user_id', REQUEST.AUTHENTICATED_USER.getUserName())">
AFAIK, Z SQL Methods only get their parameters from REQUEST. (It's been a long weekend, but I think that's what I remember.) -- Andy Dustman PGP: 0xC72F3F1D @ .net http://dustman.net/andy I'll give spammers one bite of the apple, but they'll have to guess which bite has the razor blade in it.
participants (2)
-
Andy Dustman -
McMains, Sean