Hi Developer,
I am trying to displaying the console log while selecting dropdown ‘State/Territory’ option as below screenshot:
Below is my javascript code for displaying console log message but somehow it is not working:
document.querySelector('#checkout_shipping_address_province').addEventListener('change', function(e) {
e.preventDefault();
console.log('select box');
})
I would really appreciate if you could help me have a console log message whenever the dropdown menu gets changed.
Thank you
