[Zope] Re: SV: DTML-WITH

Dieter Maurer dieter@handshake.de
Wed, 14 Feb 2001 20:30:20 +0100 (CET)


Rubinstein Fredrik writes:
 > I have for the last two hours been trying out any variation I can think 
 > of
 > using
 > restricted_traverse but I can not get it to work. Do You know where I 
 > can
 > find an working example ?

	<dtml-with "restrictedTraverse('/Test/Book')">
	  <dtml-var title_and_id>
	</dtml-with>

accesses the object "/Test/Book".

In general: "restrictedTraverse(URLPATH)"
performs URL traversal similarly to how ZPublisher would
do it. If "URLPATH" is absolute, the traversal starts at
Zope's root otherwise at the current object.


Dieter