(str) {
				if (window.location.search.substring(1).length < 1) {
					return null;
				}
				var vars = window.location.search.substring(1).split("&");
				for (var i = 0; i < vars.length; i++) {
					var pair = vars[i].split("=");
					if (pair[0] == str) {
						return pair[1];
					}
				}
				return null;
			};


			function getRootUrl() {
				var rtn = window.location.href;
				if (rtn.indexOf("?") > -1) {
					rtn = rtn.slice(0, rtn.indexOf("?"));
				}
				if (rtn.indexOf("index"