class Root:
entries = Entries()
[/quote]
but i can't for the life of me get this to work. caveat: i'm a python
newbie.
i've tried placing a file named foo.py alongside controllers.py and
importing it via
from foo import Foo
class Root:
foo = Foo()
but all i get is an error
ImportError: No module named foo
can anyone offer some pointers?
thanks,
jeff
after further investigation i found that my Foo class was being
resolved, but the template was not.
i'm using a template for foo.py in
templates/
foo/
foo.kid
still further experimentation suggests that each subdirectory of my
"templates" directory needs its own master.kid - is this correct? i
can't seem to get it to use the master in "templates"
You don't need a master template in each directory, assuming you want
to really only have one master. But, you do need to import the master
with something like
<?python
from myproject.templates import master
?>
<html py:extends="master" ...
brilliant - that's what i needed!
am i better off just keeping everything in the templates root?