Hi,

I want to use the google ajax api to get news in different languages
and display them with a tab control. The usual result does not know
the language, but I can use a context parameter. Unfortunately the
result then looks like this:

callbackFunction(
  contextValue,    // the context arg value
  responseObject,  // the collection of results and cursor
  responseStatus,  // 200 on success, non-200 on failure
  errorDetails)    // error string for non-200 response

note 4 parameters here. 
http://code.google.com/apis/ajaxsearch/documentation/reference.html#_fonje_args

The request uses onComplete : this.displayResult.bind(this) which
works fine without the context param, because the API answers with
only one param then.

I had a look into the code of mootools-1.2.4.1-more and replaced
'data' with 'arguments' here:

Request.JSONP.request_map['request_' + index] = function(data)
{ this.success(arguments, script); }.bind(this);

Now my function is called with an array of all the api arguments.

Is it safe to continue with this little diff or did I miss any side-
effects?

Reply via email to