[Zope] Displaying Graphs using TAL
Andreas Jung
lists at zopyx.com
Fri May 30 03:30:32 EDT 2008
--On 30. Mai 2008 12:38:21 +0530 Andyy <ggirotra at gmail.com> wrote:
> i am preparing graphs(MatPlotLib) related files using external methods.,
> when i test them on zope they display very well there.
>
> But when i call these external methods using tal as:
>
> <Img tal:attributes="src python: context.IterationBar(context) "/>
> where IterationBar is my external method that displays a BarChart.
>
> Or using
>
> <img src="/Agile/image.gif"
> tal:attributes="src context.IteartionBar(context)"/>
1) the thing you're calling must return an *URL*
not the image data itself...think about how the <img>
in HTML works
2) The script called through the given url must return the image
data _and_ it must set the proper http headers content-type,
and content-length
-aj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 194 bytes
Desc: not available
Url : http://mail.zope.org/pipermail/zope/attachments/20080530/7d0bad74/attachment.bin
More information about the Zope
mailing list