XML : XSLT transformation (help on syntax)

I have the following XML file I would like to use XSLT to transform into a csv file:
  <zero>      <one>          <fruit>              <apple>Red</apple>          </fruit>          <alpha:test>              <alphaA>1</alphaA>              <alphaB>2</alphaB>          </alpha:test>          <alpha:test>              <alphaA>3</alphaA>              <alphaB>4</alphaB>          </alpha:test>      </one>      <one>          <fruit>              <apple>Blue</apple>          </fruit>          <alpha:test>              <alphaA>5</alphaA>              <alphaB>6</alphaB>          </alpha:test>          <alpha:test>              <alphaA>7</alphaA>              <alphaB>8</alphaB>          </alpha:test>      </one>  </zero>    
The CSV file output should look something to this:
  Red,1,2  Red,3,4  Blue,5,6  Blue,7,8    
I did try to figure this out using XSLT with generic namespace handling, but I didn't go very far. Are there any hints/tips on how to do so?

No comments:

Post a Comment