Hi tried it out for Iframe use. IT seems to work for everything else than iframes
I get :
Error loading Razor Script [RAZOR]WidgetDropper.cshtml The best overloaded method match for 'System.Web.WebPages.Html.HtmlHelper.Raw(string)' has some invalid arguments
im using: umbraco v 4.7.1 (Assembly version: 1.0.4281.20201)
Thank you for pointing this out. I'll update the downloadable package shortly to include this update, but here's how you can fix this now if you'd like...
In the Developer section Scripting Files, edit the [RAZOR]WidgetDropper.cshtml file and scroll to the bottom of the file.
Look for this (old) section:
//# //# Actual rendering here //# <divclass="cms-widget"> @Html.Raw(node.html) </div>
And replace with this (new) section:
//# //# Actual rendering here //# <divclass="cms-widget"> @if(node.html.GetType()==typeof(umbraco.MacroEngines.DynamicXml)) { @node.html.ToHtml() } else { @Html.Raw(node.html) } </div>
The problem is because sometimes umbraco returns a string, and other times returns a DynamicXml object. As you can see, this new approach will first check before trying to render.
Widget dropper IFrame
Hi tried it out for Iframe use. IT seems to work for everything else than iframes
I get :
Error loading Razor Script [RAZOR]WidgetDropper.cshtml
The best overloaded method match for 'System.Web.WebPages.Html.HtmlHelper.Raw(string)' has some invalid arguments
im using: umbraco v 4.7.1 (Assembly version: 1.0.4281.20201)
any ideas?
Kind Regards :-)
Nicolai
Hi Nicolai,
Thank you for pointing this out. I'll update the downloadable package shortly to include this update, but here's how you can fix this now if you'd like...
In the Developer section Scripting Files, edit the [RAZOR]WidgetDropper.cshtml file and scroll to the bottom of the file.
Look for this (old) section:
And replace with this (new) section:
The problem is because sometimes umbraco returns a string, and other times returns a DynamicXml object. As you can see, this new approach will first check before trying to render.
Thanks again for reporting this!
thx - it works :-)
is working on a reply...