I want to add an additional class to an input. I have no access to the HTML to change the code.
I tried the below. I don't really know JS, but have to get this done for work.
<script type="text/javascript">
    function changeClass(){
        document.getElementById("en__field_supporter_emailAddress").className += " xverify_email";
    }
    window.onload = function(){
        document.getElementsByTagName("button").addEventListener( 'click', changeClass);
    }
</script>
I want the JS to insert the "xverify_email" class into the email address input line (which has the id en__field_supporter_emailAddress and also already has a class that must remain there) so that it can call the subsequent xverify JS to work.
 
    