You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This problem only occurs when using jquery versions prior to 2.0.
The following code will cause an error in windows 8 apps.
if ($('#css-ddslick').length <= 0 && options.embedCSS) {
$(ddslickCSS).appendTo('head');
}
This is because the windows 8 app runtime tries to prevent injection of malicious code by dynamic html injection. However, there is a function which can fix this issue: MSApp.execUnsafeLocalFunction
Thus I suggest the following workaround.
if ($('#css-ddslick').length <= 0 && options.embedCSS) {
// Special case for Windows 8 Apps
if (typeof MSApp === 'undefined') {
// Not windows 8
$(ddslickCSS).appendTo('head');
}
else {
// Windows 8
MSApp.execUnsafeLocalFunction(function () {
$(ddslickCSS).appendTo('head');
});
}
}
The text was updated successfully, but these errors were encountered:
grafxmike
added a commit
to grafxmike/ddslick
that referenced
this issue
Feb 27, 2014
I can't belive I have to type MSApp.execUnsafeLocalFunction before thousands of append() and prepend() methods for my WP8 apps. This makes no sense at all, is there another solution please? Thanks..
This problem only occurs when using jquery versions prior to 2.0.
The following code will cause an error in windows 8 apps.
This is because the windows 8 app runtime tries to prevent injection of malicious code by dynamic html injection. However, there is a function which can fix this issue: MSApp.execUnsafeLocalFunction
Thus I suggest the following workaround.
The text was updated successfully, but these errors were encountered: