So I have an xml file like this:
<?xml version="1.0"?>
<class>
<students>
<name origin="English" firstname="Jeff" lastname="Richards"/>
<name origin="French" firstname="Martel" lastname="Francois"/>
</students>
<teachers>
<name origin="Spanish" firstname="Enrique" lastname="Rosa"/>
</teachers>
</class>
And have another xml file like this:
<?xml version="1.0"?>
<name origin="English" firstname="Richard" lastname="Priestly"/>
<name origin="Russian" firstname="Alexey" lastname="Romanov"/>
Using xslt, how can I add the two elements in the second file into the student element in the first file? In other words, how can I create a file that looks like this:
<?xml version="1.0"?>
<class>
<students>
<name origin="English" firstname="Jeff" lastname="Richards"/>
<name origin="French" firstname="Martel" lastname="Francois"/>
<name origin="English" firstname="Richard" lastname="Priestly"/>
<name origin="Russian" firstname="Alexey" lastname="Romanov"/>
</students>
<teachers>
<name origin="Spanish" firstname="Enrique" lastname="Rosa"/>
</teachers>
</class>
If it is not possible using xslt, is it doable using XPath?
Thanks a bunch!