Share » Forums » Setup & design » Embedded images

Embedded images

Embedded images

Friday 20 January 2006 3:05:35 am - 5 replies

Author Message

Łukasz Serwatka

Sunday 22 January 2006 11:57:24 pm

Hi Christian,

Check in xhtml output if path in "src" attribute of <img> tag is correct. If is empty then problem probably is with image conversion system.

Have you tried to clear the image aliases cache? Do you use GD or ImageMagick?

Personal website -> http://serwatka.net
Blog (about eZ Publish) -> http://serwatka.net/blog

Christian Johansen

Monday 23 January 2006 12:41:48 am

I've tried to clear all caches many times. the src attribute is empty: src= width="" and so on.
I don't think that image magick is the problem because I can upload images, embed them in articles and preview them fine in the administration interface. I can also view the images by direct url as a user. I just cannot embed them. If I do link href='ezobject://281' it links up and the image shows. But embedding does NOT work :(

In frustration I created an override for the embed/ezimage.tpl to try to see for myself what happened. This is what I did:

<h1>Class: "{$image_class}"</h1>
{default image_class=large
         css_class=false()
         alignment=false()
         link_to_image=false()
         href=false()
         target=false()
         hspace=false()
         border_size=0}

<h1>Class/default class: "{$image_class}"</h1>

{if $image_class|eq("")}
  {let image_class='large'}
<h1>Class: "{$image_class}"</h1>
{/if}

which output:
Class: ""
Class/default class: ""
Class: ""

I give up. What's the matter here?

Łukasz Serwatka

Monday 23 January 2006 2:01:43 am

Try with image.tpl template from design/base/override/templates/embed. Make sure that correct override rule exists in your override.ini.append.php file for public siteaccess.

[image_embed]
Source=content/view/embed.tpl
MatchFile=embed/image.tpl
Subdir=templates
Match[class_identifier]=image

You can restore orginal files from ezpublish tarbal.

Personal website -> http://serwatka.net
Blog (about eZ Publish) -> http://serwatka.net/blog

Christian Johansen

Monday 23 January 2006 2:34:13 am

That worked when I put {attribute_view_gui attribute=$object.data_map.image}
I have no idea what happened here seing as it did work before... But now it works again, and I'm happy :) Thanks!

Łukasz Serwatka

Monday 23 January 2006 2:56:03 am

Great! :)

embeded object attributes you can access only via $object variable not via $node variable.

Personal website -> http://serwatka.net
Blog (about eZ Publish) -> http://serwatka.net/blog

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu