Hi All, I am newbie, and I have a problem(:. I try to make some forms showing data from MySQL about products. My structure is: - formulator object - zsql metod - add/edit page template - show page template - python script to validate and redirect between add/edit and show script. My problem is I don't know how to store value (global value) about product number (prod_no) which points to row in the table with product. Please help me (:. Best Regards -- Dawid Hulisz also known as DeHa Always look at the bright side of life Monty Python
DeHa wrote at 2004-4-27 12:58 +0200:
... My problem is I don't know how to store value (global value) about product number (prod_no) which points to row in the table with product.
What does "store" mean? In principle, Zope supports various notions of "storing": * store in REQUEST ("REQUEST.set(name,value)") The stored value is available ("REQUEST[name)") during the current request. * store in session ("REQUEST['SESSION'].set(name,value)") The stored value is available ("REQUEST['SESSION][name]") while this session is open. * store persistently as property of an object ("object.manage_addProperty(name,type,value)" (parameter order might be wrong -- check the API reference!)) The stored value is available ("object.getProperty(name)") until explicitly changed/remove. -- Dieter
Dieter Maurer wrote:
My problem is I don't know how to store value (global value) about product number (prod_no) which points to row in the table with product.
What does "store" mean?
In principle, Zope supports various notions of "storing":
* store in REQUEST ("REQUEST.set(name,value)")
The stored value is available ("REQUEST[name)") during the current request.
* store in session ("REQUEST['SESSION'].set(name,value)")
The stored value is available ("REQUEST['SESSION][name]") while this session is open.
* store persistently as property of an object ("object.manage_addProperty(name,type,value)" (parameter order might be wrong -- check the API reference!))
The stored value is available ("object.getProperty(name)") until explicitly changed/remove.
This is what I was looking for, thank You. I don't know why, but i try to understand zope from standard tutorials, but it covers just simple examples. I will still digging internet to get more knowledge (-:. And of course I'm really sorry for my english(-:. Best Regards -- Dawid Hulisz also known as DeHa Always look at the bright side of life Monty Python
participants (2)
-
DeHa -
Dieter Maurer