[Zope3-Users] browser:form

Johan Carlsson johanc at easypublisher.com
Mon Jul 18 17:45:43 EDT 2005


John Smith wrote:
> Hi Everyone,
> 
> Can anyone give me a few pointers how to use a schema
> to auto generate a form that I can use in a view of a
> content object?
> 
> The content object is a sort of "vehicle manager"
> which has an interface IVehicleManager. the Vehicle
> stores things in the ZODB like the dsn for an SQL
> database and other configuration stuff.
> 
> There is then a schema, IVehicle, which lists such
> things as colour, reqistration, make, model, year etc,
> and these details I want to store in the SQL database.
> 
> Up to now, I have been using a hand coded ZPT as a
> view object of the VehicleManager to capture Vehicle
> data.
> 
> Surely there is some way to use the IVehicle schema to
> auto-generate the form, for use outside of the ZMI.
> 
> Just a few pointers would help. For example, does the
> browser:form directive return a whole page, or do I
> somehow refer to the browser:form object from a
> separate browser:page built from .pt file?
> 
> Thanks for any help,
> 
> John

Hi John,
For the auto generate form from a schema I think:

http://www.zope.org/Wikis/DevSite/Projects/ComponentArchitecture/Zope3Book/schema.html

is the pointer you need?

Regards,
Johan


-- 
Johan Carlsson          Tel: + 46 8 31 24 94
Colliberty              Mob: + 46 70 558 25 24
Torsgatan 72            Email: johanc at easypublisher.com
SE-113 37 STOCKHOLM



More information about the Zope3-users mailing list