function participantCallback(e) { 
  var split_uri = document.location.href.split('?');
  // if there aren't any get variables we can simply add the selected value
  if(split_uri.length === 1) {
    document.location.href = "?" + this.id + "=" + this[this.selectedIndex].value;
  } else {
    // this.id is the dom id of the select tag
    // we want to remove the previous value for this select tag
    // so we can add the new one
    get_vars = remove_get_var(split_uri[1], this.id);
    if(this[this.selectedIndex].value === 'all'){
      document.location.href = "?" + get_vars
    } else {
      document.location.href = "?" + this.id + "=" + this[this.selectedIndex].value + "&" + get_vars;
    }
  }
}

function remove_get_var(current_get_vars, to_be_removed){
  get_vars_array = current_get_vars.split('&')
    my_re = new RegExp(to_be_removed);
  for (var i = 0; i < get_vars_array.length; i++) {
    if(my_re.test(get_vars_array[i])){
      get_vars_array.splice(i, 1);
    }
  }
  return get_vars_array.join("&");
}
