Fix jQuery loader to use path of itself. Fixes nested demos.

This commit is contained in:
Jörn Zaefferer
2013-03-02 18:01:40 +01:00
parent af2b388782
commit 52b2d81156

4
lib/jquery.js vendored
View File

@@ -2,6 +2,8 @@
var parts = document.location.search.slice( 1 ).split( "&" ),
length = parts.length,
scripts = document.getElementsByTagName("script"),
src = scripts[ scripts.length - 1].src,
i = 0,
current,
version = "1.9.0",
@@ -16,7 +18,7 @@ for ( ; i < length; i++ ) {
}
if (version != "git") {
file = "../lib/jquery-" + version + ".js";
file = src.replace(/jquery\.js$/, "jquery-" + version + ".js");
}