I have the following xml file
<ScheduleProvider id="257" scheduleDate="2008-03-20T15:34:18Z" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="my.xsd">
<Content action="insert" duration="7200" id="2" title="movie-2">
<EpgDescription>
<EpgElement key="Year">2002</EpgElement>
<EpgElement key="Actors">Actor2 Actor22</EpgElement>
<EpgElement key="Directors">Director2</EpgElement>
<EpgElement key="Rating">2</EpgElement>
</EpgDescription>
<EpgDescription locale="en_US">
<EpgElement key="Title">Blockbuster-2</EpgElement>
</EpgDescription>
<Media comment="" fileName="Asset_2" format="AV_ClearTS" frameDuration="180000" id="LYS008168695" title="Asset_2">
<TechnicalMetadata key="ReadyForBroadcast">4</TechnicalMetadata>
<TechnicalMetadata key="Subtitle_Languages"/>
</Media>
</Content>
<Content action="insert" duration="7200" id="1" title="movie-1">
<EpgDescription>
<EpgElement key="Year">2001</EpgElement>
<EpgElement key="Actors">Actor1 Actor11</EpgElement>
<EpgElement key="Directors">Director1</EpgElement>
<EpgElement key="Rating">1</EpgElement>
</EpgDescription>
<EpgDescription locale="en_US">
<EpgElement key="Title">Blockbuster-1</EpgElement>
</EpgDescription>
<Media comment="" fileName="Asset_1" format="AV_ClearTS" frameDuration="180000" id="LYS008168695" title="Asset_1">
<TechnicalMetadata key="ReadyForBroadcast">4</TechnicalMetadata>
<TechnicalMetadata key="Subtitle_Languages"/>
</Media>
</Content>
</ScheduleProvider>
Is it possible to sort its Content nodes by the attribute id? I'm expecting the following result
<ScheduleProvider id="257" scheduleDate="2008-03-20T15:34:18Z" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="my.xsd">
<Content action="insert" duration="7200" id="1" title="movie-1">
<EpgDescription>
<EpgElement key="Year">2001</EpgElement>
<EpgElement key="Actors">Actor1 Actor11</EpgElement>
<EpgElement key="Directors">Director1</EpgElement>
<EpgElement key="Rating">1</EpgElement>
</EpgDescription>
<EpgDescription locale="en_US">
<EpgElement key="Title">Blockbuster-1</EpgElement>
</EpgDescription>
<Media comment="" fileName="Asset_1" format="AV_ClearTS" frameDuration="180000" id="LYS008168695" title="Asset_1">
<TechnicalMetadata key="ReadyForBroadcast">4</TechnicalMetadata>
<TechnicalMetadata key="Subtitle_Languages"/>
</Media>
</Content>
<Content action="insert" duration="7200" id="2" title="movie-2">
<EpgDescription>
<EpgElement key="Year">2002</EpgElement>
<EpgElement key="Actors">Actor2 Actor22</EpgElement>
<EpgElement key="Directors">Director2</EpgElement>
<EpgElement key="Rating">2</EpgElement>
</EpgDescription>
<EpgDescription locale="en_US">
<EpgElement key="Title">Blockbuster-2</EpgElement>
</EpgDescription>
<Media comment="" fileName="Asset_2" format="AV_ClearTS" frameDuration="180000" id="LYS008168695" title="Asset_2">
<TechnicalMetadata key="ReadyForBroadcast">4</TechnicalMetadata>
<TechnicalMetadata key="Subtitle_Languages"/>
</Media>
</Content>
</ScheduleProvider>
I've heard about xsl:sort and I played with it a bit. But I have no experience with xslt and I cannot figure out how to use the xsl:sort .