I am trying to create a playlist manager and running into problems. The playlist is in xml and I am able to create tracklists, but what I want is to put tracklists within an album, and then add another album with tracklist. So the xml output is like this:
<?xml version="1.0" ?>
<playlist>
<albums>
<album id="1">
<tracks>
<track></track>
<track></track>
<track></track>
</tracks>
</album>
<album id="2">
<tracks>
<track></track>
<track></track>
<track></track>
</tracks>
</album>
</albums>
</playlist>
So far I am able to do a foreach loop for the <tracks>, but I can't find any info whether I can put that loop inside another larger foreach loop which controls the album info, or should I be creating another kind of loop within a loop structure?
any help in the logic is appreciated...
thanks!
brent