0

When I visualise an lookup field it seem like this :

enter image description here

this the code in SharePoint designer :

<tr>
                    <td width="190px" valign="top" class="ms-formlabel">
                        <H3 class="ms-standardheader">
                            <nobr>Référence</nobr>
                        </H3>
                    </td>
                    <td width="400px" valign="top" class="ms-formbody">
                        <xsl:value-of select="@R_x00e9_f_x00e9_rence_x0020_cour"/>
                    </td>
                </tr>

any ideas

2 Answers 2

1

Try stripping the HTML from the value:

<xsl:variable name="StripHTML"><![CDATA[<\s*\w.*?>|<\s*/\s*\w\s*.*?>]]></xsl:variable> 
<xsl:analyze-string select="@ows_Body" regex="{$StripHTML}">
  <xsl:non-matching-substring>
      <xsl:value-of select="."/>
  </xsl:non-matching-substring>
</xsl:analyze-string>

http://appdevonsharepoint.com/using-xslt-2-0-to-remove-html-tags-from-a-value/

1
  • do you know haw to do it with xslt version 1?
    – Imen Turki
    Oct 12, 2014 at 19:00
1

I just add this :disable-output-escaping="yes" to xsl:value-of:

<xsl:value-of select="@R_x00e9_f_x00e9_rence_x0020_cour" disable-output-escaping="yes"/>

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.