Use of glyphs (picto) to illustrate links Le template XSL "link-picture" par défaut a été modifié pour gérer l'affichage des glyphes. Si vous avez surchargé ce template, reporter les modifications dans votre surcharge.
Voici le contenu du template par défaut:
Oops! Copy to clipboard failed. Open the code and copy it manually.<xsl:template name="link-picture">
<xsl:param name="height"/>
<xsl:param name="width"/>
<xsl:if test="@pictureType != ''">
<xsl:choose>
<xsl:when test="@pictureType = 'glyph'">
<span class="picture link-glyph {@pictureGlyph}" style="font-size: {$height}px"></span>
</xsl:when>
<xsl:otherwise>
<xsl:variable name="id">
<xsl:choose>
<xsl:when test="@pictureType = 'resource'">
<xsl:value-of select="@pictureId"/>
</xsl:when>
<xsl:when test="@pictureType = 'external'">
<xsl:value-of select="concat(@picturePath, '?objectId=', @id)"/>
</xsl:when>
</xsl:choose>
</xsl:variable>
<span class="picture">
<img src="{resolver:resolveBoundedImage(@imageType, $id, $height, $width)}" alt="{@pictureAlternative}"/>
</span>
</xsl:otherwise>
</xsl:choose>
</xsl:if>
</xsl:template>
<xsl:template name="link-picture">
<xsl:param name="height"/>
<xsl:param name="width"/>
<xsl:if test="@pictureType != ''">
<xsl:choose>
<xsl:when test="@pictureType = 'glyph'">
<span class="picture link-glyph {@pictureGlyph}" style="font-size: {$height}px"></span>
</xsl:when>
<xsl:otherwise>
<xsl:variable name="id">
<xsl:choose>
<xsl:when test="@pictureType = 'resource'">
<xsl:value-of select="@pictureId"/>
</xsl:when>
<xsl:when test="@pictureType = 'external'">
<xsl:value-of select="concat(@picturePath, '?objectId=', @id)"/>
</xsl:when>
</xsl:choose>
</xsl:variable>
<span class="picture">
<img src="{resolver:resolveBoundedImage(@imageType, $id, $height, $width)}" alt="{@pictureAlternative}"/>
</span>
</xsl:otherwise>
</xsl:choose>
</xsl:if>
</xsl:template>
Voir le code
<xsl:template name="link-picture">
<xsl:param name="height"/>
<xsl:param name="width"/>
<xsl:if test="@pictureType != ''">
<xsl:choose>
<xsl:when test="@pictureType = 'glyph'">
<span class="picture link-glyph {@pictureGlyph}" style="font-size: {$height}px"></span>
</xsl:when>
<xsl:otherwise>
<xsl:variable name="id">
<xsl:choose>
<xsl:when test="@pictureType = 'resource'">
<xsl:value-of select="@pictureId"/>
</xsl:when>
<xsl:when test="@pictureType = 'external'">
<xsl:value-of select="concat(@picturePath, '?objectId=', @id)"/>
</xsl:when>
</xsl:choose>
</xsl:variable>
<span class="picture">
<img src="{resolver:resolveBoundedImage(@imageType, $id, $height, $width)}" alt="{@pictureAlternative}"/>
</span>
</xsl:otherwise>
</xsl:choose>
</xsl:if>
</xsl:template>
Dans vos autres surcharges ou autres vues du service Annuaire de liens, un lien avec un glyph sera saxée de la manière suivante :
Oops! Copy to clipboard failed. Open the code and copy it manually.<link id="linkDirectory://xxx" lang="fr" title="Titre du lien" pictureType="glyph" pictureGlyph="icomoon-date" .../>
<link id="linkDirectory://xxx" lang="fr" title="Titre du lien" pictureType="glyph" pictureGlyph="icomoon-date" .../>
<link id="linkDirectory://xxx" lang="fr" title="Titre du lien" pictureType="glyph" pictureGlyph="icomoon-date" .../>