I have a client who would like to have drop down list added to his registration form that lists all of the provinces in the world by their country code. To that end, he gave me this file. Unfortunately, the structure of the data will not work for what I need to do. Below is the structure I’d like to have. Is there some way to automatically restructure the data, perhaps by using XSLT or something similar? Thanks!
<countries>
<country code="US">
<region>Alaska</region>
<region>California</region>
</country>
</countries>
This is easily accomplished by adding a single template to the XSLT identity transform: