Sha256: 0f6d98c31e4f671efd154bd43c23f65d8d05716c6b7bddc6d36cbc21091572b0

Contents?: true

Size: 879 Bytes

Versions: 11

Compression:

Stored size: 879 Bytes

Contents

jQuery.parseQuery = function(qs) {                                                                                                                                                                                                                                   
  var q = (typeof qs === 'string' ? qs : window.location.search);
  var ret = [];
  q.replace(/#.*$/,'');
  q.replace(/([^?&=]+)=?([^&]*)(?:&+|$)/g, function(match, key, value) {
    ret.push( { 'name': decodeURIComponent(key.replace(/\+/g,' ')), 'value': decodeURIComponent(value.replace(/\+/g,' ')) });
  });
  return ret;
}
jQuery.parseQuerySimple = function(querystring) {
  var q = jQuery.parseQuery(querystring);
  var ret = {};
  jQuery.each(q,function(k,v){
    ret[v.name] = v.value;
  });
  return ret;
}
jQuery.parseFragment = function(querystring) {
  return window.location.hash;
}

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
cpee-2.0.30 tools/test/js_libs/parsequery.js
cpee-2.0.28 tools/test/js_libs/parsequery.js
cpee-2.0.27 tools/test/js_libs/parsequery.js
cpee-2.0.26 tools/test/js_libs/parsequery.js
cpee-2.0.25 tools/test/js_libs/parsequery.js
cpee-2.0.24 tools/test/js_libs/parsequery.js
cpee-2.0.23 tools/test/js_libs/parsequery.js
cpee-2.0.22 tools/test/js_libs/parsequery.js
cpee-2.0.21 tools/test/js_libs/parsequery.js
cpee-2.0.20 tools/test/js_libs/parsequery.js
cpee-1.4.27 cockpit/js_libs/parsequery.js