Search

Hello!

I'm getting my head around symphony, and I've been trying to make these persona objects on my site. Name, Age, Photo. After some fidling around I got the image to show by writing:

http://www.mytestpage.com/workspace/images/persona/

<xsl:attribute name="alt">
    <xsl:value-of select="image/filename" />
</xsl:attribute>

which seems kinda wrong. So I've been trying to do it something like this:

$filename

but I get the feeling I'm missing some major step here.. Do I need to edit something in the corresponding Section or Data Source? So that the filename is also selectable as a variable in the html tag.

Sorry if I come across really confused. I am.

wrap your xpath or variable calls with curly braces:

<img src="{$workspace}{image/@path}/{image/filename}" alt="{image/filename}" />

Aah..

Nice of you to respond so soon and getting it right.. I'm going to experiment some more with that. Read up on xpath some more.

Thanks a lot.

Create an account or sign in to comment.

Symphony • Open Source XSLT CMS

Server Requirements

  • PHP 5.3-5.6 or 7.0-7.3
  • PHP's LibXML module, with the XSLT extension enabled (--with-xsl)
  • MySQL 5.5 or above
  • An Apache or Litespeed webserver
  • Apache's mod_rewrite module or equivalent

Compatible Hosts

Sign in

Login details