[Zope] absolute newbie question

Kevin Dangoor kid@kendermedia.com
Sat, 28 Aug 1999 16:59:02 -0400


-----Original Message-----
From: lethal@innocent.com <lethal@innocent.com>
To: zope@zope.org <zope@zope.org>
Date: Saturday, August 28, 1999 4:40 PM
Subject: [Zope] absolute newbie question


>well, yes, it's not a problem in the management screen, no question.
>this works fine. but i am thinking of a web page one can open in a
>browser window without logging in or using the management screen.
>there, for example, one should be able to post a message and this
>message will be put into the odb.
>
>something like <!--#setProperty (msgText, REQUEST ['mgs']) -->
>
>(dumb question?)

Not a dumb question at all... I do this kind of thing all the time with
Zope, and it is not necessarily completely obvious.

If you want to set the value of a property, all you need to do is call:
<dtml-call "manage_changeProperties({'propname' : propvalue})">

An alternate form, if the properties are all in the REQUEST variable (via a
form, or whatever) and the REQUEST variables have the same names as the
properties:
<dtml-call "manage_changeProperties(REQUEST)">

If you don't want to log in to make the change, use a "Proxy Role" on the
DTML Method. You can set the proxy role to "Manager", and then that
particular method can do anything a Manager can do.

Kevin