开发者

Content Query web part Rendering HTML source

开发者 https://www.devze.com 2023-02-17 10:38 出处:网络
We are using a Content Query web partto 开发者_如何学编程query for a specific reusable HTML content item and display it in a page layout (so it exists on every page) but it is appearing as HTML source

We are using a Content Query web part to 开发者_如何学编程query for a specific reusable HTML content item and display it in a page layout (so it exists on every page) but it is appearing as HTML source, not rendered HTML. Any idea?


For me I had to do the reverse, and enable output escaping.

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


You'll have to customise the ItemStyle.xsl file (ie: by creating a copy and adding your own style) which prints out the content - and specify disable-output-escaping="no".

Like this:

 <xsl:value-of select="@Value" disable-output-escaping="no" />

Here's how to customise the ItemStyle: http://www.heathersolomon.com/blog/articles/CustomItemStyle.aspx

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号