[Zope] Cookie pointer.

Cesar A. K. Grossmann cesar@rotnet.com.br
Mon, 25 Sep 2000 19:35:27 -0300


Steve Drees wrote:
> 
> > What can I do to this code works?
> 
> Can you cut and paste the offending code?

Exactly the same of the message of Thomas:

<dtml-if expr="RESPONSE.setCookie('name', 'value', path='/',
expires=(ZopeTime() + (1.0/102.0))">
         "You have cookies enabled"
<dtml-else>
  "Your browser does not support cookies"
</dtml-if>

If I get rid of the 'expires' parameter, I receive allways the same
"Your browser does not support cookies". Even when the cookies suport is
enabled... The code changed looks like:


<p>
Cookies

<dtml-call "RESPONSE.setCookie('name', 'value', path='/')">

<dtml-if "RESPONSE.cookies['name']=='value'">
  enabled.

<dtml-else>
  disabled.
</dtml-if>

<dtml-call "RESPONSE.expireCookie('name')">

</p>

(spaces/blank lines added to make it more readable).

-- 
César A. K. Grossmann ckant@usa.net http://members.xoom.com/ckant/
http://www.halcyon.com/sciclub/cgi-pvt/instr/instr.html