Remove URL parameter from URL and reload the page in JavaScript
Method: function removeParam(key, sourceURL) { var rtn = sourceURL.split(“?”)[0], param, params_arr = [], queryString = (sourceURL.indexOf(“?”) !== -1) ? sourceURL.split(“?”)[1] : “”; if (queryString !== “”) { params_arr = queryString.split(“&”); for (var i = params_arr.length – 1; i >= 0;β¦