Bonjour,
Voici mon problème, je souhaite transformer en préservant le saut de ligne:
en
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3 <UML:Comment xmi.id="I72e3fdfem11b44ab414cmm7db9" name="" visibility="public" isSpecification="false" body="Use to autorize or not stock event for the facility and it's components">
J'utilise le code suivant :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6 <UML:Comment XXX> <UML:Comment.body>Use to autorize or not stock event for the facility and it's components </UML:Comment.body> </UML:Comment>
Et voici le résultat que j'obtient sur un seule et unique ligne:
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8 <xsl:template match="UML:Comment"> <UML:Comment xmi.id="{@xmi.id}" owner="{../../@xmi.id}"> <UML:Comment.body> <xsl:value-of select="@body"/> </UML:Comment.body> </UML:Comment> </xsl:template>
Je me suis intéréssé à xsl:preserve-space mais impossible d'en tirer quoique ce soit...
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4 <UML:Comment XXX> <UML:Comment.body>Use to autorize or not stock event for the facility and it's components</UML:Comment.body> </UML:Comment>
Merci d'avance pour votre aide.
Partager