[Zope] expected string or Unicode object,
ImplicitAcquirerWrapper found
Marc Lindahl
marc at bowery.com
Mon Mar 22 12:57:15 EST 2004
I must be missing something... help!
I have a python script called logoName.py, as follows:
return 'logo.jpg'
then I'm trying to use that in a DTML method. This works fine:
&dtml-portal_url;/&dtml-logoName;
Whereas this gives me an error:
<dtml-var "_[logoName].getURL">
the error traceback being:
-------------------
Exception Type TypeError
Exception Value expected string or Unicode object,
ImplicitAcquirerWrapper found
Traceback (innermost last):
* Module ZPublisher.Publish, line 98, in publish
* Module ZPublisher.mapply, line 88, in mapply
* Module ZPublisher.Publish, line 39, in call_object
* Module Products.CMFCore.FSDTMLMethod, line 141, in __call__
* Module DocumentTemplate.DT_String, line 474, in __call__
* Module DocumentTemplate.DT_With, line 76, in render
* Module DocumentTemplate.DT_Util, line 201, in eval
__traceback_info__: logoName
* Module <string>, line 2, in f
* Module AccessControl.DTML, line 32, in guarded_getitem
* Module AccessControl.ZopeGuards, line 90, in guarded_getitem
TypeError: expected string or Unicode object, ImplicitAcquirerWrapper
found
-------------------
I really need to use the latter construct, is it possible to change my
python script to give it the right thing?
M
More information about the Zope
mailing list