Updated to hook and adapted for Phoenix based on code snippets published on the forum by @De Dokta.
This requires the replacement or edit of one core file so only use if your happy doing this.
It will automaticity turn the state select input filed into a drop-down on the selection of a country that has states. This is done without the need to do a page refresh or submit.
Make getting a new account a much better experience for the customer.
That’s it Enjoy.. Has been tested on Phoenix Version 188.8.131.52 only.