David Bear
David.Bear at asu.edu
Thu May 18 12:08:22 EDT 2006
When using psp called from publisher, what is the namespace shared between the instance of publisher and the called psp? I modelled a test of the templating example from modpython.org. I have a function call _any_page that is called to setup any/all objects passed to a psp page. in that function I have vars = {"mytest": "this is atest"} then, in my psp page I have <%= mytest %> When run, ie. when called from the publisher script I get a Namerror exception -- that mytest is not defined. so then I tried <%= locals() %> in the psp page and looked at the namespace. I didn't see any of the vars defined in the publisher script. -- David Bear phone: 480-965-8257 fax: 480-965-9189 College of Public Programs/ASU Wilson Hall 232 Tempe, AZ 85287-0803 "Beware the IP portfolio, everyone will be suspect of trespassing"
|