On to, 12.06.2003 at 11:03 +0200, Nikel, Ernst-Dieter wrote:
I have the following problem:
For example consider the code:
<dtml-in "test.ba.objectValues()"> <dtml-var id> </dtml-in>
This gives the ids in the folder test/ba.
My problem is that in my applcation I get the path like "test/ba" in the example through a REQUEST. The script
<dtml-in "_[tt].ba.objectValues()"> <dtml-var id> </dtml-in>
works if the variable "tt" contains the value "test". But I don't have found a possibility to call the method if the given path (or better the relevant part of the path) contains more than one folder.
The code
<dtml-in "_[tt].objectValues()"> <dtml-var id> </dtml-in>
don't works if the variable "tt" contains "test.ba".
I don't know dtml, but you can probably translate this python code to dtml: for k in container.REQUEST.resolve_url(tt).objectValues(): print k.getId() If you have the full url, you can use request.resolve_url() to get the object, and call objectValues() on that. -- paavo. "joskus voi tää meno käydä ahdistavaksi kun on täällä muodostunut tavaksi muuttaa jokaisen elämän arvo rahaksi"