Tuesday, December 16, 2014

how to add ScriptEditorWebPart to PageLayout

the simple secret is that the ID of the webpart MUST be a guid, example

<WebPartPages:ScriptEditorWebPart
    runat="server"
    Content="&lt;script&gt;alert(&#39;hi&#39;);&lt;/script&gt;"
    ID="g_9db1223f_1234_44df_ad5d_e6454520ddfa" >
</WebPartPages:ScriptEditorWebPart>

No comments:

Post a Comment