Trying to just put together some simple javascript to change the action location on a form, this is the code i'm using
<script>
var x = document.getElementsByClassName("wpcf7-form");
x[0].action = "process/formdata.php";
</script>
However nothing happens. Any ideas?