[Zope] Newbie Question: date formatting/Context

Ashley Lloyd ashleylloyd@hotmail.com
Mon, 06 Jan 2003 14:23:08 +0000


I am new to both Zope and OOP, so please be patient with my ignorance and 
stupidity!

I am running Zope 2.5.1, connecting to an InterBase db using kinterbas.

I have been experiencing problems attempting to retrieve any date values 
from the db in any format other than YYYY-MM-DD HH:MM:SS.ss. In an attempt 
to solve this I have downloaded mxDateTime, and have been able to use this 
fine in the Python IDLE environment, but not in Zope. I saved a small Python 
script in my Zope environment just to try it out:

from mx.DateTime import *
while 1:
  return now().hour

However, when attempting to test this I get prompted for username/password 
(I am logged in as a manager etc) and then get the following error:

Error Type: Unauthorized
Error Value: You are not allowed to access DateTime in this context

I have been trying to read about this, and the books seem to say that this 
can happen, but not what to do about it.

If anyone can help with any part of the problem (the security problem or 
another option for date formatting - or both!!) I'd be grateful.

Kind regards

Ashley

PS Sorry if this question appears twice - I tried to post earlier in the day 
and cannot seem to find any sign of it.


_________________________________________________________________
The new MSN 8: smart spam protection and 2 months FREE*  
http://join.msn.com/?page=features/junkmail