I tried to get a conditional to check if there is a image/thumb/etc. defined, and if not, i want to display a placeholder for each _tpl/img/img_XxY.tpl. No success was with $image->defined. Which is the recommended way, always display an specific image if e.g. {{ include file="_tpl/img/img_250x167.tpl" where="front-bottom" }} is chosen.
Might is be possible to check {{ if ! $gimme->article->image->thumbnailurl }} ? Or wont there be an thumbnail?
Where should placeholder pictures being placed ? (or referenced) - which is the <img src="{{ xxx }}"> path, when placing images below current template, e.g. /themes/publication_1/theme_1/_img/ (which variable contains /themes/publication_1/theme_1/_img/ ) ?
You can put placeholder images anywhere inside your theme's folder, for example /img. Accessing them is easy with {{ uri static_file="img/placeholder.jpg" }}
Best, Ljuba
On Monday, 11 June 2012, BAUMANN Thomas wrote:
> Hi Ljuba, > > Might is be possible to check {{ if ! $gimme->article->image->thumbnailurl > }} ? Or wont there be an thumbnail? > > Where should placeholder pictures being placed ? (or referenced) - which > is the path, when placing images below current template, e.g. > /themes/publication_1/theme_1/_img/ (which variable contains > /themes/publication_1/theme_1/_img/ ) ? > >
-- Ljuba Rankovic Senior Front End Developer, Sourcefabric ljuba.rankovic@sourcefabric.org
in this case class applied to <figure> is created when variable $where has value 'author', and this value is forwarded from parent template (let's say article.tpl) to this included template like this
{{ include file="img/img_600x400.tpl" where="author" }}
-- Ljuba Rankovic Senior Front End Developer, Sourcefabric ljuba.rankovic@sourcefabric.org