[Plone-UI] Page template needs gif used to be conditional of the current path

Mayank Mathur mayankmathur at tetrain.com
Wed Sep 3 13:02:51 UTC 2008


try this :
    <img tal:attributes="
                                src string:${portal_url}/<img>;

inside <metal>  ........ </metal> tags

Regards,
Mayank Mathur




treid wrote:
> Hello
>
> I have a viewlet page template called portal_bottom.pt that calls gif for
> display.
>
> I would like the gif used to be conditional of the current path.
>
> So if the URL starts with "domain.com/special-path" I would like the image
> to be displayed "image-b.gif" otherwise I would like the image to be
> "image-a.gif"
>
> img src="/path/to/graphic/image-" if URL starts with "/special-path" "b.gif"
> else "a.gif"  ...
>
> I'm guessing a little python is needed here but I don't know python so could
> someone help me out please?
>
> Thanks
>
> Tony 
>   




More information about the UI mailing list