----- Original Message -----
From: Ian Sparks <[EMAIL PROTECTED]>
> The conceptual problem I have is that DTMLMethods/Documents don't have a
> parameters tag like SQLMethods do, so I don't see how I can "trap" parts
> the URL like SQLMethods do and use them internally in my Method/Document.

There isn't an automatic way to do this; SQLMethods are specially written to
be traversable.  There are three (fairly complex) ways to do this that I can
think of:

1.  Subclass DTMLDocument and mix in the class SQLMethods use for
traversability.  Probably hard.

2.  Use a PythonMethod, and make one of its parameters 'traverse_subpath'.
Then you can traverse through this PythonMethod and use the parameter to do
what you want.  Not bad, but you need to know PythonMethods.

3.  Use a SiteAccess Access Rule on the folder, having it check to see if
the next object to be traversed is your DTMLMethod.  If so (and if the next
name doesn't start with 'manage'!) remove the rest of the traversal path and
store it in a REQUEST variable.  Not too bad, but SiteAccess is fragile (it
doesn't work with Zope 2.2a).


Evan @ digicool & 4-am

Zope maillist  -  [EMAIL PROTECTED]
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-dev )

Reply via email to