3 Jun
2008
3 Jun
'08
5:28 p.m.
Malthe Borch wrote:
However, trying to get the absolute url of the resource fails, and it seems to be an acquisition-wrapping thing.
FWIW, this adapter will do the trick, although it's hardly a solid solution: class SimpleResourceAbsoluteURL(object): interface.implements( zope.traversing.browser.interfaces.IAbsoluteURL) component.adapts( Products.Five.browser.resource.DirectoryResource, zope.publisher.interfaces.browser.IDefaultBrowserLayer) def __init__(self, context, request): self.context = context def __str__(self): return self.context() \malthe