[Zope3-Users] Skinning problem
Florian Lindner
mailinglists at xgm.de
Wed Jan 17 15:50:58 EST 2007
Hello,
I have a ressourceDirectory with a file styles.css
<resourceDirectory
directory="files"
name="files"
/>
I refer to it in my default template:
<link rel="stylesheet" type="text/css" tal:attributes="href
context/@@/files/styles.css" />
since the template is registered with macro_pages is also used by third party
components (resp. a component developed by myself but should also be usuable
independed).
The problem is that when the template is used with the component it does not
find the styles.css (all pages are registered on the default layer).
The external component calls the macro like that:
<html metal:use-macro="views/standard_macros/view">
The template file offers a macro view:
<metal:block define-macro="view">
The error message is:
File "/home/florian/Zope3/src/zope/tales/tales.py", line 696, in evaluate
return expression(self)
- /home/florian/Desktop/zope/lib/python/xgm/browser/skin/template.pt
- Line 9, Column 8
- Expression: <PathExpr standard:u'context/@@/files/styles.css'>
- Names:
{'args': (),
'context': <Blog.blog.Blog object at 0xb677f76c>,
'default': <object object at 0xb7f6c568>,
'loop': {},
'nothing': None,
'options': {},
'repeat': {},
'request': <zope.publisher.browser.BrowserRequest instance
URL=http://horus.local:8080/++skin++xgm/xgm/Blog/@@view.html>,
'template':
<zope.app.pagetemplate.viewpagetemplatefile.ViewPageTemplateFile object at
0xb6de5e2c>,
'view': <zope.app.pagetemplate.simpleviewclass.SimpleViewClass
from /home/florian/Desktop/zope/lib/python/Blog/browser/bloglisting.pt object
at 0xb678486c>,
'views': <zope.app.pagetemplate.viewpagetemplatefile.ViewMapper object
at 0xb6784bcc>}
[...]
File "/home/florian/Zope3/src/zope/interface/adapter.py", line 482, in
queryMultiAdapter
result = factory(*objects)
TypeError: 'unicode' object is not callable
What is the problem?
Thanks,
Florian
More information about the Zope3-users
mailing list