public/javascripts/inputex/js/rpc/yql.js
function(yql, callback) {
		 var ud = 'yqlexecuteconsole'+(inputEx.YQL.query_index)++,
		      API = 'http://query.yahooapis.com/v1/public/yql?q=',
		      url = API + window.encodeURIComponent(yql) + '&format=json&diagnostics=true&callback=' + ud;
		 window[ud]= function(o){ callback && callback(o); };
	    document.body.appendChild((function(){
		    var s = document.createElement('script');
          s.type = 'text/javascript';
	       s.src = url;
	       return s;
	    })());	
	}
function(yql, callback) {
		 var ud = 'yqlexecuteconsole'+(inputEx.YQL.query_index)++,
		      API = 'http://query.yahooapis.com/v1/public/yql?q=',
		      url = API + window.encodeURIComponent(yql) + '&format=json&diagnostics=true&callback=' + ud;
		 window[ud]= function(o){ callback && callback(o); };
	    document.body.appendChild((function(){
		    var s = document.createElement('script');
          s.type = 'text/javascript';
	       s.src = url;
	       return s;
	    })());	
	}
function ( yql , callback ) { var ud = 'yqlexecuteconsole' + ( inputEx . YQL . query_index ) ++ , API = 'http://query.yahooapis.com/v1/public/yql?q=' , url = API + window . encodeURIComponent ( yql ) + '&format=json&diagnostics=true&callback=' + ud ; window [ ud ] = function ( o ) { callback && callback ( o ) ; } ; document . body . appendChild ( ( function ( ) { var s = document . createElement ( 'script' ) ; s . type = 'text/javascript' ; s . src = url ; return s ; } ) ( ) ) ; }
Generate the jsonp request to YQL
@param {String} yql YQL query string
@param {Function} callback Callback function
Generate the jsonp request to YQL