Search

Hi,
I'd like to convert this pseudo-sql code to something useful -- datasource, output parameters etc

Select u.username, u.avatar, p.username 
from users as u, posts as p 
where u.username = p.username

In brief, I have a bunch of posts written by different members, for whom I have to display the avatar. Do not know where to start from...

Thanks!

Solved, it was not a datasource problem, but a xpath one.

<img alt="" class="icon">
<xsl:attribute name="src">
<xsl:value-of select="concat($root, '/image/smallavatar', '/uploads/', //users-posts/entry[@id = current()/user/item/@id]/avatar/filename)"/>
</xsl:attribute>
</img>

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