[Zope] Execute a PageTemplate in another context

Peter Bengtsson peter at fry-it.com
Mon Feb 4 11:17:17 EST 2008


Is it possible to execute a PageTemplate as if it was located somewhere 
else?
The PageTemplate has this code::
<html><br tal:replace="here/absolute_url_path"/></html>

And it's located in a folder called /foo/bar/ which are normal Zope 
Folder objects.
I'm executing this template object from Python code (not from URL 
travsersal) and the rendered result is:
<html>/foo/bar</html>

But what if I want to execute it as if it existed in another context, 
e.g. /barfoo
Is that possible?

I can imagine a some convoluted solutions but was hoping for something 
easy and obvious that I've missed.

-- 
Peter Bengtsson,
work www.fry-it.com
home www.peterbe.com
hobby www.issuetrackerproduct.com


More information about the Zope mailing list