Hallo,
stehe vor einem seltsamen Problem.
ich habe eine XML-Datei:
[XML]<?xml version="1.0"?>
<xmap-content version="2.0" xmlns="urn:xmind:xmap:xmlns:content:2.0" xmlns:fo="http://www.w3.org/1999/XSL/Format" xmlns:svg="http://www.w3.org/2000/svg" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:xlink="http://www.w3.org/1999/xlink">
<sheet id="05kogoti6q7p7o552qqnk9msp4">
<topic id="5mc1923l0om840hk45jpogkako" timestamp="1277382542303">
<title>Berufsbilder</title>
<children>
<topics type="attached">
<topic id="04taqi0s7tg0ar6f72bqqhlfac" timestamp="1277298961641">
<title>EDV-Techniker</title>
<children>
<topics type="attached">
<topic id="75oo7lm1m0luv1efthj5rarvs1" timestamp="1277298455030">
<title>1.1.1</title>
<children>
<topics type="attached">
<topic id="681on2rui88a2hvbcot0n5sgu1" timestamp="1277298489678">
<title>Einführung in die Aufgaben des Betriebes (Branchenstellung, Erzeugungsprogramm, Dienstleistungsprogramm, Vertriebsprogramm)</title>
</topic>
</topics>
</children>
</topic>
<topic id="554184evsj9jmurbbrov0blgon" timestamp="1277298511098">
<title>1.1.2</title>
</topic>
<topic id="15sahrvg9jbh7th4udulhc3bb2" timestamp="1277298520453">
<title>1.1.3</title>
</topic>
<topic id="3nu5g40ag686o5r51b5tv6ni1g" timestamp="1277298523368">
<title>1.1.4</title>
</topic>
<topic id="34k224no0e3d5572u5gbe84o15" timestamp="1277298534079">
<title>1.2.1</title>
</topic>
<topic id="501jlev4idt2964fdjn802aejc" timestamp="1277298545739">
<title>1.2.2</title>
</topic>
<topic id="33t5dfmt496n7rbj9m6j89h30t" timestamp="1277298553804">
<title>1.2.3</title>
</topic>
<topic id="1oprlfj1qp85cesmm4pht5kcqa" timestamp="1277298556996">
<title>1.2.4</title>
</topic>
<topic id="0l3us2a7fd2165ltthr2a83285" timestamp="1277298559776">
<title>1.2.5</title>
</topic>
<topic id="5as551h72otb3mas7ikq2ea4m2" timestamp="1277298598369">
<title>1.3.1</title>
<children>
<topics type="attached">
<topic id="3gvtqp68pjms7uqs0rn6qv02t3" timestamp="1277298890430">
<title>Kenntnis der sich aus dem Lehrvertrag ergebenden Verpflichtungen (§§ 9 und 10 des Berufsausbildungsgesetzes)</title>
<children>
<topics type="attached">
<topic id="0vbraigmt7j4lpckg9c892i4ja" timestamp="1277298895993">
<title>Recht</title>
</topic>
</topics>
</children>
</topic>
</topics>
</children>
</topic>
<topic id="5ucs0ucl169d8ogp0q6h80kut4" timestamp="1277298630814">
<title>1.3.2</title>
<children>
<topics type="attached">
<topic id="6t9arbstq8q702lq0dm7dg95iu" timestamp="1277298630809">
<title>Kenntnis über Inhalt und Ziel der Ausbildung sowie über wesentliche einschlägige Weiterbildungsmöglichkeiten</title>
</topic>
</topics>
</children>
</topic>
<topic id="3nk81hvkdvmsoh3qheaknadkhn" timestamp="1277298660099">
<title>1.3.3</title>
<children>
<topics type="attached">
<topic id="464huvc57o2q616ia4u70064lq" timestamp="1277298660094">
<title>Kenntnis über Arbeitsorganisation und Arbeitsgestaltung, Teamarbeit und Projektarbeit</title>
</topic>
</topics>
</children>
</topic>
<topic id="0i3llnqh7tscao41fn51m1cpnt" timestamp="1277298946907">
<title>1.3.4</title>
</topic>
<topic id="6tl8u51dkdueloq19os60ej7qd" timestamp="1277298988547">
<title>2.1.1</title>
<children>
<topics type="attached">
<topic id="5oc28tl1tbv1pij2arhtgong8d" timestamp="1277455410796">
<title>Kenntnis über Hardware und Software, Peripherie, Betriebssysteme und Anwenderprogramme</title>
</topic>
</topics>
</children>
</topic>
</topics>
</children>
</topic>
<topic id="3p0nus0bqlbp1eefpeodfse5pe" timestamp="1277382561143">
<title>Kommunikationstechniker</title>
</topic>
</topics>
</children>
</topic>
<title>Arbeitsblatt 1</title>
</sheet>
</xmap-content>[/XML]
sieht nicht kompliziert aus, oder?!
jetzt will ich sie so umwandeln, dass ich sie dann in Excel einlesen kann.
Habe mal eine "leere" XSL-Datei:
[XML]<?xml version="1.0"?>
<xsl:stylesheet
version="2.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xslutput
method="xml"
version="1.0"
encoding="iso-8859-1"
indent="yes"/>
<xsl:template match="/test/sheet/topic/children">
</xsl:template>
</xsl:stylesheet>[/XML]
mein erwartetes Ergebnis wäre vorläufig mal ... NICHTS!
Mein Ergebnis sieht aber so aus:
[XML]<?xml version="1.0" encoding="iso-8859-1"?>BerufsbilderEDV-Techniker1.1.1Einf�hrung in die Aufgaben des Betriebes (Branchenstellung, Erzeugungsprogramm, Dienstleistungsprogramm, Vertriebsprogramm)1.1.21.1.31.1.41.2.11.2.21.2.31.2.41.2.51.3.1Kenntnis der sich aus dem Lehrvertrag ergebenden Verpflichtungen (�� 9 und 10 des Berufsausbildungsgesetzes)Recht1.3.2Kenntnis �ber Inhalt und Ziel der Ausbildung sowie �ber wesentliche einschl�gige Weiterbildungsm�glichkeiten1.3.3Kenntnis �ber Arbeitsorganisation und Arbeitsgestaltung, Teamarbeit und Projektarbeit1.3.42.1.1Kenntnis �ber Hardware und Software, Peripherie, Betriebssysteme und AnwenderprogrammeKommunikationstechnikerArbeitsblatt 1[/XML]
... das wirkt für mich so, als würde der Parser einfach ALLE Text-Nodes herausschreiben! Wieso tut er das?!
Wie kann ich das verhindern?! Das will ich doch gar nicht!
mfg, guni
stehe vor einem seltsamen Problem.
ich habe eine XML-Datei:
[XML]<?xml version="1.0"?>
<xmap-content version="2.0" xmlns="urn:xmind:xmap:xmlns:content:2.0" xmlns:fo="http://www.w3.org/1999/XSL/Format" xmlns:svg="http://www.w3.org/2000/svg" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:xlink="http://www.w3.org/1999/xlink">
<sheet id="05kogoti6q7p7o552qqnk9msp4">
<topic id="5mc1923l0om840hk45jpogkako" timestamp="1277382542303">
<title>Berufsbilder</title>
<children>
<topics type="attached">
<topic id="04taqi0s7tg0ar6f72bqqhlfac" timestamp="1277298961641">
<title>EDV-Techniker</title>
<children>
<topics type="attached">
<topic id="75oo7lm1m0luv1efthj5rarvs1" timestamp="1277298455030">
<title>1.1.1</title>
<children>
<topics type="attached">
<topic id="681on2rui88a2hvbcot0n5sgu1" timestamp="1277298489678">
<title>Einführung in die Aufgaben des Betriebes (Branchenstellung, Erzeugungsprogramm, Dienstleistungsprogramm, Vertriebsprogramm)</title>
</topic>
</topics>
</children>
</topic>
<topic id="554184evsj9jmurbbrov0blgon" timestamp="1277298511098">
<title>1.1.2</title>
</topic>
<topic id="15sahrvg9jbh7th4udulhc3bb2" timestamp="1277298520453">
<title>1.1.3</title>
</topic>
<topic id="3nu5g40ag686o5r51b5tv6ni1g" timestamp="1277298523368">
<title>1.1.4</title>
</topic>
<topic id="34k224no0e3d5572u5gbe84o15" timestamp="1277298534079">
<title>1.2.1</title>
</topic>
<topic id="501jlev4idt2964fdjn802aejc" timestamp="1277298545739">
<title>1.2.2</title>
</topic>
<topic id="33t5dfmt496n7rbj9m6j89h30t" timestamp="1277298553804">
<title>1.2.3</title>
</topic>
<topic id="1oprlfj1qp85cesmm4pht5kcqa" timestamp="1277298556996">
<title>1.2.4</title>
</topic>
<topic id="0l3us2a7fd2165ltthr2a83285" timestamp="1277298559776">
<title>1.2.5</title>
</topic>
<topic id="5as551h72otb3mas7ikq2ea4m2" timestamp="1277298598369">
<title>1.3.1</title>
<children>
<topics type="attached">
<topic id="3gvtqp68pjms7uqs0rn6qv02t3" timestamp="1277298890430">
<title>Kenntnis der sich aus dem Lehrvertrag ergebenden Verpflichtungen (§§ 9 und 10 des Berufsausbildungsgesetzes)</title>
<children>
<topics type="attached">
<topic id="0vbraigmt7j4lpckg9c892i4ja" timestamp="1277298895993">
<title>Recht</title>
</topic>
</topics>
</children>
</topic>
</topics>
</children>
</topic>
<topic id="5ucs0ucl169d8ogp0q6h80kut4" timestamp="1277298630814">
<title>1.3.2</title>
<children>
<topics type="attached">
<topic id="6t9arbstq8q702lq0dm7dg95iu" timestamp="1277298630809">
<title>Kenntnis über Inhalt und Ziel der Ausbildung sowie über wesentliche einschlägige Weiterbildungsmöglichkeiten</title>
</topic>
</topics>
</children>
</topic>
<topic id="3nk81hvkdvmsoh3qheaknadkhn" timestamp="1277298660099">
<title>1.3.3</title>
<children>
<topics type="attached">
<topic id="464huvc57o2q616ia4u70064lq" timestamp="1277298660094">
<title>Kenntnis über Arbeitsorganisation und Arbeitsgestaltung, Teamarbeit und Projektarbeit</title>
</topic>
</topics>
</children>
</topic>
<topic id="0i3llnqh7tscao41fn51m1cpnt" timestamp="1277298946907">
<title>1.3.4</title>
</topic>
<topic id="6tl8u51dkdueloq19os60ej7qd" timestamp="1277298988547">
<title>2.1.1</title>
<children>
<topics type="attached">
<topic id="5oc28tl1tbv1pij2arhtgong8d" timestamp="1277455410796">
<title>Kenntnis über Hardware und Software, Peripherie, Betriebssysteme und Anwenderprogramme</title>
</topic>
</topics>
</children>
</topic>
</topics>
</children>
</topic>
<topic id="3p0nus0bqlbp1eefpeodfse5pe" timestamp="1277382561143">
<title>Kommunikationstechniker</title>
</topic>
</topics>
</children>
</topic>
<title>Arbeitsblatt 1</title>
</sheet>
</xmap-content>[/XML]
sieht nicht kompliziert aus, oder?!
jetzt will ich sie so umwandeln, dass ich sie dann in Excel einlesen kann.
Habe mal eine "leere" XSL-Datei:
[XML]<?xml version="1.0"?>
<xsl:stylesheet
version="2.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xslutput
method="xml"
version="1.0"
encoding="iso-8859-1"
indent="yes"/>
<xsl:template match="/test/sheet/topic/children">
</xsl:template>
</xsl:stylesheet>[/XML]
mein erwartetes Ergebnis wäre vorläufig mal ... NICHTS!
Mein Ergebnis sieht aber so aus:
[XML]<?xml version="1.0" encoding="iso-8859-1"?>BerufsbilderEDV-Techniker1.1.1Einf�hrung in die Aufgaben des Betriebes (Branchenstellung, Erzeugungsprogramm, Dienstleistungsprogramm, Vertriebsprogramm)1.1.21.1.31.1.41.2.11.2.21.2.31.2.41.2.51.3.1Kenntnis der sich aus dem Lehrvertrag ergebenden Verpflichtungen (�� 9 und 10 des Berufsausbildungsgesetzes)Recht1.3.2Kenntnis �ber Inhalt und Ziel der Ausbildung sowie �ber wesentliche einschl�gige Weiterbildungsm�glichkeiten1.3.3Kenntnis �ber Arbeitsorganisation und Arbeitsgestaltung, Teamarbeit und Projektarbeit1.3.42.1.1Kenntnis �ber Hardware und Software, Peripherie, Betriebssysteme und AnwenderprogrammeKommunikationstechnikerArbeitsblatt 1[/XML]
... das wirkt für mich so, als würde der Parser einfach ALLE Text-Nodes herausschreiben! Wieso tut er das?!
Wie kann ich das verhindern?! Das will ich doch gar nicht!
mfg, guni