Is there a way to add (not include) a query string parameter on the URL from the target.
Use case is as follows:
Use case is as follows:
Hi @mayurik
You can use custom code option in VEC. Add custom javascript to append query parameters in the URL. you can use following JS code.
function insertParam(key, value) {
key = encodeURIComponent(key);
value = encodeURIComponent(value);
// kvp looks like ['key1=value1', 'key2=value2', ...]
var kvp = document.location.search.substr(1).split('&');
let i=0;
for(; i<kvp.length; i++){
if (kvp[i].startsWith(key + '=')) {
let pair = kvp[i].split('=');
pair[1] = value;
kvp[i] = pair.join('=');
break;
}
}
if(i >= kvp.length){
kvp[kvp.length] = [key,value].join('=');
}
// can return this or...
let params = kvp.join('&');
// reload page with new params
document.location.search = params;
}
query.append("test","true");
let me know if this works.
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.