Skip to content

Instantly share code, notes, and snippets.

@slackorama
Created December 16, 2008 19:45
Show Gist options
  • Save slackorama/36760 to your computer and use it in GitHub Desktop.
Save slackorama/36760 to your computer and use it in GitHub Desktop.
(function() {
var oldXhr = dojo.xhr;
dojo.xhr = function(/*String*/ method, /*dojo.__Scrags*/ args,
/*Boolean?*/ hasBody){
// first clone so we don't screw up original caller
var cloneargs = dojo.mixin( {}, args );
if (cloneargs.url) {
cloneargs.url = 'myfunkyurl?a=' + cloneargs.url;
}
return oldXhr.apply( dojo, [ method, cloneargs, hasBody]);
};
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment