For My Own Future Reference

function getQueryString(){
	var query = window.location.search.substring(1);
	var items = query.split("&");
	var result = {};
	for(var index=0;index<items.length;++index){
		var position = items[index].indexOf("=");
		if(position>0){
			var key = items[index].substring(0,position);
			var value = items[index].substring(position+1);
			result[key]=value;
		}
	}
	return result;
}
Advertisements

Tags: , ,

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s


%d bloggers like this: