selectivizr icon indicating copy to clipboard operation
selectivizr copied to clipboard

IE onload error [solved]

Open john-warpdevelopment opened this issue 12 years ago • 3 comments

I was using IE9 compatibility mode to simulate IE7 (issue was also in IE8 document mode) included selectivizr v1.0.3b and on load it would error in the resolveUrl function on the line

if (url.charAt(0) == "/") {
            return getProtocolAndHost(contextUrl) + url;
        }

The error was in the if, the variable url was undefined. So without really knowing what that function does, i seem to have been able to solve the issue by adding this line near the top of the function

if (!url) return "";

john-warpdevelopment avatar Feb 14 '12 08:02 john-warpdevelopment

I should mention that the when I tried to check for the null in the if statement that my styling on my page was broken , so i suspect it might have something to do with less (http://lesscss.org/) at the time using v1.1.3.

john-warpdevelopment avatar Feb 14 '12 08:02 john-warpdevelopment

same here, have to monkey-patch it for now

emirotin avatar Aug 31 '12 08:08 emirotin

We had a similar issue, though v1.0.3b and pull request 34 fixed it (https://github.com/keithclark/selectivizr/pull/34).

mlhDevelopment avatar Apr 03 '13 12:04 mlhDevelopment