[xml] Replacing parts of xml with xsl



Dear All,

I hopefully have a simple problem.

I have a xml file, say

<AAA>
    <BBB>test 1</BBB>
    <BBB>test 2</BBB>
    <CCC />
</AAA>

I want to use a xsl style sheet to change a part of the xml that is
specified with an xpath expression.

For example /AAA/BBB[1] & <DDD>new test</DDD>, would give

<AAA>
   <DDD>new test</DDD>
    <BBB>test 2</BBB>
    <CCC />
</AAA>

Any help is appreciated.

Thanks
Colin



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]