how to create brain instance in python???
Greetings, I have need to create a brain instance in a python script. How do i do this? The reason is, that i want to return to a page template from a python script a brain instance that is either the result of a catalog query, or an empty/default instance. Then, the template can fill a form field with either the retrieved values or defaults. The Catalog currently contains only objects of a single Meta Type. Thanks, mark -------------------------------------------------------------------- mail2web - Check your email from the web at http://mail2web.com/ .
The reason is, that i want to return to a page template from a python script a brain instance that is either the result of a catalog query, or an empty/default instance. Then, the template can fill a form field with either the retrieved values or defaults.
In this situation, why not just return a dictionary for your default? It's probably gonna smell enough like a brain to work as expected... cheers, Chris
participants (2)
-
Chris Withers -
mlilly@tinorb.com