X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=modules%2Foverride%2FCGI%2FAjax.pm;h=95cefece3866efa91e51cd4413490eb41c919211;hb=6d6eb2decd2f3561ae4f4591269165cffce88b25;hp=41e9c33429cd076f3122f794e0d7daf17774307a;hpb=fcc318eb414179e86e2cd827183485f6a89ea9fc;p=kivitendo-erp.git diff --git a/modules/override/CGI/Ajax.pm b/modules/override/CGI/Ajax.pm index 41e9c3342..95cefece3 100644 --- a/modules/override/CGI/Ajax.pm +++ b/modules/override/CGI/Ajax.pm @@ -834,23 +834,25 @@ pjx.prototype = { readyState4 : function(){ var rsp = $decodefn(this.r.responseText); /* the response from perl */ var splitval = '__pjx__'; /* to split text */ - /* fix IE problems with undef values in an Array getting squashed*/ - rsp = rsp.replace(splitval+splitval+'g',splitval+" "+splitval); var data = rsp.split(splitval); dt = this.target; if (dt.constructor != Array) { dt=[dt]; } if (data.constructor != Array) { data=[data]; } - if (typeof(dt[0])!='function') { + if (typeof(dt[0])=='function') { + dt[0].apply(this,data); + } else { for ( var i=0; i