Javascript in RSS Viewer web part XSLT in SharePoint 2013
I tried to add simple Javascript (calling alert) in the XSLT of an RSS Viewer web part; but, the alert never gets called on the page. I have tried all possible places; but, unable to find any resolution.
This is how I add the code within the XSLT:
<script type="text/javascript" defer="true">
<xsl:text>
<![CDATA[
alert('xslt hi');
]]>
</xsl:text></script>
I have done this successfully in SharePoint 2010.
The alert works when added in a simple CEWP on the same page.
Please let me know what am I missing and a resolution to this issue.