I want to extract a query string from my URL using JavaScript, and I want to do a case insensitive comparison for the query string name. Here is what I am doing:
<
You can add 'i' modifier that means "ignore case"
var results = new RegExp('[\\?&]' + name + '=([^]*)', 'i').exec(window.location.href);