Forums / General / Templates and images...

Templates and images...

Author Message

Jerry Jalava

Monday 16 June 2003 3:23:30 am

Hi,
I would like to know how can I get only image variables (ie. Path) to templates? If I use attribute_view_gui it creates the hole image inserting line (<img src=...).

Regards,
Jerry

Karsten Jennissen

Monday 16 June 2003 4:54:10 am

Try the ezimage operator {"/subpathcurrentdesign/image.ext"|ezimage}

See
http://ez.no/developer/ez_publish_3/documentation/ez_publish_3/terminology_basics/template_language

Karsten

Jerry Jalava

Monday 16 June 2003 6:27:58 am

Thanks for your reply, but...

That doesn't help me in this case. I should have been more specific... :)
This picture witch attributes I need is added in the same article class at the sametime it is published. So, I cannot specify the image with ezimage...

The name of my image attribute in article class is "Kirjoittaja_kuva" and identifier "kirjoittaja_kuva", so I need to know how to implement this picture with specific size to the template. Best would be fetching only the image path and using that inside hardcoded image tag in template...

Thanks,
Jerry

Helena Vauchez

Friday 20 June 2003 3:32:15 am

Hi Jerry
you can specify attributes for the img-tag like this:
{attribute_view_gui attribute=$content_version.data_map.<your_img_identifier> border_size=0 name="foo"}
look in design/standard/templates/content/datatype/view/ezimage.tpl to see the names of the possible attributes.
"name" for example is not there - so I wrote my own ezimage.tpl.

hope that helps
Helena