[Zope] Accessing pythonscripts in different branch

Geir Bækholt Geir Bækholt
Tue, 25 Mar 2003 12:35:05 +0100


On  Tue, 25 Mar 2003 12:27:24 +0100 GMT (..12:27 where i live(GMT+1) )
Ria Marinussen asked the Zope mailinglist about the following:
RM> On my zope site I use some pythonscripts. I don't like them to be in the
RM> root of my site, but can't figure out how to access them when they'r not in
RM> the root.
...
RM> I use a python script for that by including it in my
RM> standard_dtml_header file like this:
RM> <dtml-var expr="topmenu('branch1')">
...
RM> Is it possible to move this script to a folder "scripts" and access the
RM> script on every page in my website? (How?)

<dtml-var expr="scripts.topmenu('branch1')">
everything inside expr="" is evaluated as a python expression

if you are not using expr="", the following should also work
(although not with the explicit paramter-passing):
<dtml-with scripts>
    <dtml-var topmenu>
</dtml-with>


--
Geir Bækholt