function getBaseUrl(sUrl) {
		var aMatches = sUrl.match(/http.+\(S\(.+\)\)\//);

		if (!Array.isArray(aMatches) || aMatches.length < 1) {
			throw new Error("Could not find a base URL in " + sUrl);
		}

		return aMatches[0];
	}
Returns the base URL from a given URL.
@param {string} sUrl - the complete URL
@returns {string} the base URL