Splice a `querystring` from an `url`;

@param {String} url
@return {String}
@api public
179674
function split(url) {
  assert.equal(typeof url, 'string', 'url-querystring: url should be a string');

  var res = {};
  var nw = url.split('?');

  res.url = nw[0];
  res.qs = nw.length == 2
    ? qs.parse(nw[1])
    : {};

  return res;
}
100403
function( url ) {
            var match = url.match(/^([a-z]+:)\/\//i);
            if ( match === null ) {
                // Relative URL, retrive the protocol from window.location
                return window.location.protocol;
            }
            return match[1].toLowerCase();
        }
114795
function appendQueryStringOptions(requestUrl, queryStringOptions) {
    requestUrl += "?";
    for (var prop in queryStringOptions) {
        if (queryStringOptions.hasOwnProperty(prop)) {
            requestUrl += prop + "=" + queryStringOptions[prop] + "&";
        }
    }

    //Remove the last & from the string
    requestUrl = requestUrl.substr(0, requestUrl.length - 1);
    return requestUrl;
}
1144631
function(url) {
			var paths = this.paths;
			for(var index = 0; index < paths.length; index++) {
				var path = paths[index];
				if (path === url.substring(0, path.length)) {
					return url.substring(path.length);
				}
			}
			return url;
		}
247903
function(url) {
		var query = getQueryString(url);
		for (var name in query) {
			if (query[name] === '?') {
				return name;
			}
		}
		return null;
	}
1034938
function (url) {
            var tmp = url.replace(/\burl\s*/gi, "");    // removing url word
            tmp = tmp.charAt(0) === "(" ? tmp.substring(1, tmp.length - 1) : tmp; // removing brackets
            tmp = tmp.charAt(0) === "\'" || tmp.charAt(0) === "\"" ? tmp.substring(1, tmp.length - 1) : tmp; // removing quotes
            return tmp;
        }
300988
function (url) {
            return url
                .replace(/[\/]+/g, '/')
                .replace(/\/\?/g, '?')
                .replace(/\/\#/g, '#')
                .replace(/\:\//g, '://');
        }
760178
function splitURL(url) {
    var method, path, match = /^([A-Z]+)(?:\s+|$)/.exec(url);
    if (match) {
        method = match[1];
        path = /^[A-Z]+\s+(.*)$/.exec(url);
        url = path ? path[1]: '';
    }
    return {url: url, method: method};
}
53199
function(first) {
    if (first === "/") {
        return "/" + _url_join.apply(_url_join, [].splice.call(arguments, 1));
    } else {
        return _url_join.apply(_url_join, [].splice.call(arguments, 0));
    }
}
566839
function queryStringToObject(queryString) {
        var pairs = queryString.split('&');
        var result = {};
        pairs.forEach(function (pair) {
            pair = pair.split('=');
            result[pair[0]] = decodeURIComponent(pair[1] || '');
        });
        return JSON.parse(JSON.stringify(result));
    }
691424
function(url) {
			var index = url ? url.lastIndexOf('/') : -1;
			return index == -1 ? url : url.substring(0, index + 1);
		}
1242478
function(_url,_data){
            var _sep = _url.indexOf('?')<0?'?':'&',
                _data = _data||'';
            if (_u._$isObject(_data))
                _data = _u._$object2query(_data);
            if (!!_data) _url += _sep+_data;
            return _url;
        }
292349
def clean_url(url, force_scheme=None):
    """"""
    # URL should be ASCII according to RFC 3986
    url = str(url)
    # Collapse ../../ and related
    url_parts = urlparse.urlparse(url)
    path_parts = []
    for part in url_parts.path.split('/'):
        if part == '.':
            continue
        elif part == '..':
            if path_parts:
                path_parts.pop()
        else:
            path_parts.append(part)

    url_parts = list(url_parts)
    if force_scheme:
        url_parts[0] = force_scheme
    url_parts[2] = '/'.join(path_parts)

    if FLAGS.keep_query_string == False:
        url_parts[4] = ''    # No query string

    url_parts[5] = ''    # No path

    # Always have a trailing slash
    if not url_parts[2]:
        url_parts[2] = '/'

    return urlparse.urlunparse(url_parts)
798505
protected function RemoveQueryString($url, Request $request)
    {
        if (isset($url) && !empty($url)) {
            $parts = explode('&', $url);

            if (strpos($parts[0], '=') === false) {
                $url = $parts[0];
            } else {
                $url = self::RemoveQueryString($request->getQueryString());
            }
        }

        return $url;
    }
39470
function(url, key, value) {
    var queryStrPos = url.indexOf('?');
    var anchorStrPos = url.lastIndexOf('#');
    
    var paramSeparator = '&';
    
    if(queryStrPos < 0) {
        // There's no query string.
        paramSeparator = '?';
    }
    
    if (anchorStrPos > 0) {
        // There's an anchor at the end, we need to insert our parameter before it
        var urlBeforeAnchor = url.substring(0, anchorStrPos);
        var urlAnchor = url.substring(anchorStrPos);
        return urlBeforeAnchor + paramSeparator + key + '=' + value + urlAnchor;
    } else {
        return url + paramSeparator + key + '=' + value;
    }
}
56098
function getExtension(url) {
    var a = url.split('.');

    if (a.length === 1 || (a[0] === '' && a.length === 2))
      return '';
    return a.pop();
  }
1254692
function getUrl(url) {
        if (urlReg.test(url)) {
            return RegExp.$5 + (RegExp.$6 ? RegExp.$6 : "");
        } else {
            "console" in window && console.error("[url error]:", url);
        }

    }