mirror of
https://github.com/jquery/jquery.git
synced 2024-11-23 02:54:22 +00:00
changed $.execute back to eval()
This commit is contained in:
parent
66f124a658
commit
6596108635
@ -123,7 +123,7 @@ $.fn.load = function(a,o,f) {
|
|||||||
$.xml(t,a,o,function(res){
|
$.xml(t,a,o,function(res){
|
||||||
// Assign it and execute all scripts
|
// Assign it and execute all scripts
|
||||||
self.html(res.responseText).find("script").each(function(){
|
self.html(res.responseText).find("script").each(function(){
|
||||||
try { $.execute( this.text || this.textContent || this.innerHTML || ""); } catch(e){}
|
try { eval( this.text || this.textContent || this.innerHTML || ""); } catch(e){}
|
||||||
});
|
});
|
||||||
|
|
||||||
// Callback function
|
// Callback function
|
||||||
@ -316,7 +316,7 @@ $.fn.putForm = function(target, pre_cb, post_cb, url, mth) {
|
|||||||
$(target).load(url, this.vars, post_cb);
|
$(target).load(url, this.vars, post_cb);
|
||||||
} else {
|
} else {
|
||||||
this.vars.push({name: 'evaljs', value: 1});
|
this.vars.push({name: 'evaljs', value: 1});
|
||||||
$.xml(mth, url, $.param(this.vars), function(r) { $.execute(r.responseText); });
|
$.xml(mth, url, $.param(this.vars), function(r) { eval(r.responseText); });
|
||||||
}
|
}
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
|
6
jquery/jquery.js
vendored
6
jquery/jquery.js
vendored
@ -318,8 +318,6 @@ function $(a,c) {
|
|||||||
return self;
|
return self;
|
||||||
}
|
}
|
||||||
|
|
||||||
$.execute = eval;
|
|
||||||
|
|
||||||
$.apply = function(o,f,a) {
|
$.apply = function(o,f,a) {
|
||||||
a = a || [];
|
a = a || [];
|
||||||
if ( f.apply ) {
|
if ( f.apply ) {
|
||||||
@ -330,7 +328,7 @@ $.apply = function(o,f,a) {
|
|||||||
p[i] = 'a['+i+']';
|
p[i] = 'a['+i+']';
|
||||||
}
|
}
|
||||||
o.$$exec = this;
|
o.$$exec = this;
|
||||||
var r = $.execute('o.$$exec(' + p.join(',') + ')');
|
var r = eval('o.$$exec(' + p.join(',') + ')');
|
||||||
o.$$exec = null;
|
o.$$exec = null;
|
||||||
return r;
|
return r;
|
||||||
}
|
}
|
||||||
@ -625,7 +623,7 @@ $.filter = function(t,r,not) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if ( f !== null ) {
|
if ( f !== null ) {
|
||||||
$.execute('f = function(a,i){return ' + f + '}');
|
eval('f = function(a,i){return ' + f + '}');
|
||||||
r = g( r, f );
|
r = g( r, f );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user