[z3-five] BrowserView and AttributeError on getPhysicalPath
Rob Miller
robm at openplans.org
Wed Jul 12 21:02:19 CEST 2006
On Wed, 12 Jul 2006 15:07:42 +0100, Tim Hicks wrote:
> Hi,
>
> I have a view.py module that looks like:
>
> # Five imports
> from Products.Five import BrowserView from
> Products.Five.browser.pagetemplatefile \
> import ZopeTwoPageTemplateFile as PageTemplateFile
>
>
> class TopicView(BrowserView):
> """
> """
>
> topic_listing = PageTemplateFile('./topic_listing.pt')
> author_listing = PageTemplateFile('./author_listing.pt') topic_view
> = PageTemplateFile('./topic_view.pt')
>
>
> I have a ZCML snippet that looks like:
>
> <browser:page
> for=".interfaces.IWeblog"
> class=".browser.view.TopicView"
> attribute="topic_listing"
> permission="zope2.View"
> name="topics" />
i don't know what, exactly, is causing your error, but to accomplish the
same result i'd usually just use the "template" attribute on the
browser:page directive rather than using attribute. then you can remove
the attributes from the view class.
this may not fix your problem, but it's worth trying, anyway.
-r
More information about the z3-five
mailing list