I am trying to add additional hidden fields to WordPress admin login form to exclude it from hubspot which is created using Elementor Pro's Login widget. I used the below hook but it does not work:
<?php
function your_function( $user_login, $user ) {
?>
<label for="amex" style="display:none">AMEX</label>
<input type="hidden" name="amex" required="" value="" id="amex">
<?php
}
add_action('wp_login', 'your_function', 10, 2);
?>