function getIdFromQstring() {

//Retrieve Document location and tear off the QueryString values for processing.
var url = document.location + '';
q=url.split('?');
if (q[1]) {
	//Get all Name/Value pairs from the QueryString
	var pairs = q[1].split('&');
	for (i=0;i<pairs.length;i++) {

		//Get the Name from given Name/Value pair
		var keyval = pairs[i].split('=');

		if (keyval[0] == 'id') {
			//Get the Value from given Name/Value pair and set to the return ID
			var squareid = keyval[1];
		}

	}
}

return squareid;
}

//var setID = getIdFromQstring();
