[Zope] REQUEST.set doesn't set in 2.2.4

Dieter Maurer dieter@handshake.de
Thu, 7 Dec 2000 21:47:38 +0100 (CET)


Brad Clements writes:
 > This code:
 > 
 > <dtml-call "REQUEST.set('verrormessage',orderobject.chargeCard(REQUEST,Holmes.CyberCash,Rec))">
 > <!-- charge result is &dtml-verrormessage;-->
 > 
 > Prints out _.None as the result.
 > 
 > However a print statement in my ordeobject.chargeCard method shows 
 > that the return value isn't None.
Are you sure that you do not have a "verrormessage" variable or
object attribute/property around?

   The definitions in REQUEST have quite a low priority.
   They are usually at the bottom of the namespace stack
   and there at the bottom of the acquisition context.

   This implies:

     If you have any variable on the namespace stack,
     it will hide a REQUEST value bound to the same name.
     Same is true, for acquired names.

You may use <dtml-var "REQUEST['verrormessage']" html_quote>
or:

	<dtml-with REQUEST>
	  &dtml-verrormessage;
	</dtml-with>


Dieter