Please don't post to the list in HTML.
James Johnson wrote:
> I'm trying to get the basic app building concept down with
> Forgive me if I'm way off the mark. I'm building off the guest
> example from the new Zope book. What I've done is created a
> folder call Gbook. Inside I've created a dtml method index_html, a
> specialist named Guestbook and a Dataskin instance called
> Guestbook_entry. I have one property sheet named GBookProps defined
> for dataskin ZClass. Instead of storing the guestbook entries in
> documents I'm trying to store them using the dataskin database.
> In the Specialist(Guestbook) I have 3 methods addEntry,
> addEntryAction, and addEntryForm
> When I call addEntry I get.
> sequence-index must be an integer
> I thought I was so close to understanding me not understanding. :)
> It seems to me that the "only" way to produce a ZPatterns based
> product is to do it from python.
> How about this, should I be trying to add entries this way?
> """dtml method addEntry"""
> <dtml-var standard_html_header>
> <h2> Inserting new Guest Book Table Info Item!</h2>
> <dtml-let id="'entry_%d' % len(self.objectIds())">
This is a bit odd -- you're closing your dtml-let tag immediately after
Also, I don't understand your call to newItem. You should be passing an
id into it.
> <dtml-call "ni.propertysheets.manage_addPropertySheet
> (id='GBookProps', ns=''
You probably ought to close the bracket, quote and tag here.
> <dtml-let nips="ni.propertysheets.get('GBookProps')">
The variable "ni" won't be bound to anything in particular here.
> <dtml-call "nips.manage_addProperty('guest_name', guest_name,
> <dtml-call "nips.manage_changeProperties(REQUEST)">
> <form action=index_html>
> <input type=submit value="OK">
You can use ZPatterns from DTML alone quite easily. However, some things
are easier from an external method or a python method.
Zope-Dev maillist - [EMAIL PROTECTED]
** No cross posts or HTML encoding! **
(Related lists -