Channel Image?

Sam Ruby rubys at intertwingly.net
Thu Oct 26 04:28:08 EST 2006


Nick Moffitt wrote:
> Shane Graber:
>> Is there a plan to add this to any of the Planet or Venus templates?
> 
> I used to have template logic to use the upstream image:
> 
> <TMPL_IF channel_face>
> <a href="<TMPL_VAR channel_link ESCAPE="HTML">" title="<TMPL_VAR channel_title ESCAPE="HTML">"><img class="face" src="face/<TMPL_VAR channel_face ESCAPE="HTML">" width="<TMPL_VAR channel_facewidth ESCAPE="HTML">" height="<TMPL_VAR channel_faceheight ESCAPE="HTML">" alt=""></a>
> <TMPL_ELSE>
>     <TMPL_IF channel_image_url>
>         <img src="<TMPL_VAR channel_image_url>" class="face" alt="<TMPL_VAR channel_image_title>" />
>     </TMPL_IF>
> </TMPL_IF>
> 
> I haven't worked this into my current venus install, but it used to work
> great.

First, I'll note that these are two separate features.

Nick is wondering if images referenced by feeds are available to 
templates.  Shane is noting that images referenced by the configuration 
are available to templates (in Planet, and presumably in Venus).

As to Nick's question, I've dug into the code, and it looks like only 
Atom icons and logos are/were supported.  I've just rectified this for 
Venus: in the latest bzr, rss 1.0 and 2.0 image elements are now mapped 
to atom:icon (for xslt) and 'icon' (for htmltmpl).

- Sam Ruby


More information about the devel mailing list