Can you not just make a new reference before the ajax call? DB_info.prototype.get_column_details = function(obj, table, column) {
someRef=this; //or DB_info.prototype, or whatever you prefer $.post(this.db_info_script, { action: "get_column_details", table: table, column: column}, function(json) { // Watch out, here comes the tricky part someRef.results = json; }, "json"); return true; > > } > > The tricky part, or the part I'm having trouble with, is how to set > DB_info.results = to the json results of the $.post call. I realize > that the problem at the tricky part is that "this" at that point is > refering to the jQuery object, but DB_info.results and > DB_info.prototype.results don't seem to work either. > > Is there anyway I can pass something through the $.post callback so > that my ajaxComplete listeners can get to that json object? Or is > there an obvious better way to do be doing all this in the first > place. > > Again, thanks all for reading!