Skip to content

Commit

Permalink
script urls dont remove any part of the url before loading
Browse files Browse the repository at this point in the history
  • Loading branch information
thatcher committed Feb 5, 2010
1 parent 569158c commit c2b7abc
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 4 deletions.
4 changes: 3 additions & 1 deletion dist/env.js
Expand Up @@ -123,6 +123,7 @@ Envjs.loadLocalScript = function(script){
src,
i,
base,
filename,
// SMP: see also the note in html/document.js about script.type
script_type = script.type === null ?
"text/javascript" : script.type;
Expand Down Expand Up @@ -163,7 +164,8 @@ Envjs.loadLocalScript = function(script){
}
}
base = "" + script.ownerDocument.location;
var filename = Envjs.location(script.src.match(/([^\?#]*)/)[1], base );
//filename = Envjs.location(script.src.match(/([^\?#]*)/)[1], base );
filename = Envjs.location(script.src, base );
try {
load(filename);
console.log('loaded %s', filename);
Expand Down
4 changes: 3 additions & 1 deletion dist/env.rhino.js
Expand Up @@ -123,6 +123,7 @@ Envjs.loadLocalScript = function(script){
src,
i,
base,
filename,
// SMP: see also the note in html/document.js about script.type
script_type = script.type === null ?
"text/javascript" : script.type;
Expand Down Expand Up @@ -163,7 +164,8 @@ Envjs.loadLocalScript = function(script){
}
}
base = "" + script.ownerDocument.location;
var filename = Envjs.location(script.src.match(/([^\?#]*)/)[1], base );
//filename = Envjs.location(script.src.match(/([^\?#]*)/)[1], base );
filename = Envjs.location(script.src, base );
try {
load(filename);
console.log('loaded %s', filename);
Expand Down
4 changes: 3 additions & 1 deletion dist/platform/core.js
Expand Up @@ -123,6 +123,7 @@ Envjs.loadLocalScript = function(script){
src,
i,
base,
filename,
// SMP: see also the note in html/document.js about script.type
script_type = script.type === null ?
"text/javascript" : script.type;
Expand Down Expand Up @@ -163,7 +164,8 @@ Envjs.loadLocalScript = function(script){
}
}
base = "" + script.ownerDocument.location;
var filename = Envjs.location(script.src.match(/([^\?#]*)/)[1], base );
//filename = Envjs.location(script.src.match(/([^\?#]*)/)[1], base );
filename = Envjs.location(script.src, base );
try {
load(filename);
console.log('loaded %s', filename);
Expand Down
4 changes: 3 additions & 1 deletion src/env/core/html.js
Expand Up @@ -48,6 +48,7 @@ Envjs.loadLocalScript = function(script){
src,
i,
base,
filename,
// SMP: see also the note in html/document.js about script.type
script_type = script.type === null ?
"text/javascript" : script.type;
Expand Down Expand Up @@ -88,7 +89,8 @@ Envjs.loadLocalScript = function(script){
}
}
base = "" + script.ownerDocument.location;
var filename = Envjs.location(script.src.match(/([^\?#]*)/)[1], base );
//filename = Envjs.location(script.src.match(/([^\?#]*)/)[1], base );
filename = Envjs.location(script.src, base );
try {
load(filename);
console.log('loaded %s', filename);
Expand Down

0 comments on commit c2b7abc

Please sign in to comment.