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
_______________________________________________
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users

Reply via email to