Click here to Skip to main content
15,885,546 members
Home / Discussions / XML / XSL
   

XML / XSL

 
AnswerRe: Does anyone know how to take a XML file and store it into a C++ structure? Pin
pmarfleet12-Apr-08 8:05
pmarfleet12-Apr-08 8:05 
GeneralRe: Does anyone know how to take a XML file and store it into a C++ structure? Pin
Mike A. Fowler12-Apr-08 9:30
Mike A. Fowler12-Apr-08 9:30 
AnswerRe: Does anyone know how to take a XML file and store it into a C++ structure? Pin
pmarfleet12-Apr-08 10:33
pmarfleet12-Apr-08 10:33 
GeneralRe: Does anyone know how to take a XML file and store it into a C++ structure? Pin
Mike A. Fowler13-Apr-08 3:30
Mike A. Fowler13-Apr-08 3:30 
GeneralRe: Does anyone know how to take a XML file and store it into a C++ structure? Pin
pmarfleet13-Apr-08 3:45
pmarfleet13-Apr-08 3:45 
GeneralXML versioning Pin
helen.gonzalez9-Apr-08 22:23
helen.gonzalez9-Apr-08 22:23 
GeneralRe: XML versioning Pin
led mike10-Apr-08 5:56
led mike10-Apr-08 5:56 
GeneralMaintain the order of the xml Pin
Yariv9-Apr-08 20:38
Yariv9-Apr-08 20:38 
Hi,

I'm generating an xml dynamically and want to use xsl as a template (and therefore not generated dynamically).
Here is an example of such xml:

<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="Template.xsl"?>
<PeopleList order="1">
<item>
<Name>John</Name>
</item>
<item>
<Name>Doe</Name>
</item>
</PeopleList>
<KidList order="2">
<item>
<Name>Alex</Name>
</item>
<item>
<Name>King</Name>
</item>
</KidList>

Template.xsl looks like this:

<?xml version="1.0" encoding="ISO-8859-1"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"><xsl:template match="/">
<html>
<body>
<h2>My List</h2>
<xsl:apply-templates select="KidList"/>
<xsl:apply-templates select="PeopleList"/>
</body>
</html>
</xsl:template>
<xsl:template match="PeopleList">
<p> People List </p>
</xsl:template>
<xsl:template match="KidList">
<p> KidList </p>
</xsl:template>
</xsl:stylesheet>

Result will be (the order was decided according xsl:apply-templates and not according the xml) :

My List


Kid List


People List




In the xml, PeopleList can come before KidList or after it and the order is matter - I want one xsl file that can display them in the right order.
I added an "order" attribute but still don't know if it can help and how.
Any suggestions?
GeneralRe: Maintain the order of the xml Pin
Mark J. Miller14-Apr-08 6:33
Mark J. Miller14-Apr-08 6:33 
GeneralRe: Maintain the order of the xml Pin
Yariv14-Apr-08 10:13
Yariv14-Apr-08 10:13 
GeneralRe: Maintain the order of the xml Pin
Mark J. Miller14-Apr-08 10:33
Mark J. Miller14-Apr-08 10:33 
GeneralRe: Maintain the order of the xml Pin
Yariv14-Apr-08 20:41
Yariv14-Apr-08 20:41 
Generalxml serialization arraylist Pin
omer erakman8-Apr-08 20:37
omer erakman8-Apr-08 20:37 
GeneralRe: xml serialization arraylist Pin
led mike9-Apr-08 5:03
led mike9-Apr-08 5:03 
GeneralRe: xml serialization arraylist Pin
omer erakman11-Apr-08 1:17
omer erakman11-Apr-08 1:17 
GeneralShowing "&" sign in XML file Pin
Rajeeshun7-Apr-08 14:27
Rajeeshun7-Apr-08 14:27 
GeneralRe: Showing "&" sign in XML file [modified] Pin
logiclabz7-Apr-08 20:47
logiclabz7-Apr-08 20:47 
GeneralRe: Showing "&" sign in XML file Pin
K.P.Kannan8-Apr-08 15:43
K.P.Kannan8-Apr-08 15:43 
GeneralTotal Noobie Pin
abesimpson2-Apr-08 9:53
abesimpson2-Apr-08 9:53 
GeneralRe: Total Noobie Pin
led mike2-Apr-08 11:06
led mike2-Apr-08 11:06 
GeneralAuto Populate and email Word document From ASP.NET 2.0 using xslt/xml Pin
Wilsy2-Apr-08 2:16
Wilsy2-Apr-08 2:16 
Question[Message Deleted] Pin
malarpm2-Apr-08 1:47
malarpm2-Apr-08 1:47 
GeneralRe: Need help in generating xml file using the xsd file in classic asp. Pin
led mike2-Apr-08 4:45
led mike2-Apr-08 4:45 
QuestionCan we lock just a single table in xml file?? Pin
Ron.S1-Apr-08 19:46
Ron.S1-Apr-08 19:46 
AnswerRe: Can we lock just a single table in xml file?? Pin
led mike2-Apr-08 4:42
led mike2-Apr-08 4:42 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.