Forum |  HardWare.fr | News | Articles | PC | S'identifier | S'inscrire | Shop Recherche
2949 connectés 

  FORUM HardWare.fr
  Programmation
  XML/XSL

  [XSL]Une idee pour recuperer une info precise

 


 Mot :   Pseudo :  
 
Bas de page
Auteur Sujet :

[XSL]Une idee pour recuperer une info precise

n°1264283
tellier
Posté le 12-12-2005 à 09:20:48  profilanswer
 

Voila, j'ai un fichier xml contenant entre autre cette partie:
 

Code :
  1. <Row ss:AutoFitHeight="0">
  2.     <Cell ss:MergeAcross="1" ss:StyleID="s29"><Data ss:Type="String">cs</Data></Cell>
  3.    </Row>
  4.    <Row>
  5.     <Cell ss:StyleID="s22"><Data ss:Type="String">Indication of the product:&#160;</Data></Cell>
  6.     <Cell ss:StyleID="s22"><Data ss:Type="String">Náramkové hodinky</Data></Cell>
  7.    </Row>
  8.    <Row>
  9.     <Cell ss:StyleID="s22"><Data ss:Type="String">Indication of the product:&#160;</Data></Cell>
  10.     <Cell ss:StyleID="s22"><Data ss:Type="String">Sluchátka (náhlavní)</Data></Cell>
  11.    </Row>
  12.    <Row ss:AutoFitHeight="0">
  13.     <Cell ss:MergeAcross="1" ss:StyleID="s29"><Data ss:Type="String">da</Data></Cell>
  14.    </Row>
  15.    <Row>
  16.     <Cell ss:StyleID="s22"><Data ss:Type="String">Indication of the product:&#160;</Data></Cell>
  17.     <Cell ss:StyleID="s22"><Data ss:Type="String">Armbåndsure</Data></Cell>
  18.    </Row>
  19.    <Row>
  20.     <Cell ss:StyleID="s22"><Data ss:Type="String">Indication of the product:&#160;</Data></Cell>
  21.     <Cell ss:StyleID="s22"><Data ss:Type="String">Hovedtelefoner</Data></Cell>
  22.    </Row>
  23.    <Row ss:AutoFitHeight="0">
  24.     <Cell ss:MergeAcross="1" ss:StyleID="s29"><Data ss:Type="String">de</Data></Cell>
  25.    </Row>
  26.    <Row>
  27.     <Cell ss:StyleID="s22"><Data ss:Type="String">Indication of the product:&#160;</Data></Cell>
  28.     <Cell ss:StyleID="s22"><Data ss:Type="String">Armbanduhren</Data></Cell>
  29.    </Row>
  30.    <Row>
  31.     <Cell ss:StyleID="s22"><Data ss:Type="String">Indication of the product:&#160;</Data></Cell>
  32.     <Cell ss:StyleID="s22"><Data ss:Type="String">Hörer (Kopf- )</Data></Cell>
  33.    </Row>
  34.    <Row ss:AutoFitHeight="0">
  35.     <Cell ss:MergeAcross="1" ss:StyleID="s29"><Data ss:Type="String">el</Data></Cell>
  36.    </Row>
  37.    <Row>
  38.     <Cell ss:StyleID="s22"><Data ss:Type="String">Indication of the product:&#160;</Data></Cell>
  39.     <Cell ss:StyleID="s22"><Data ss:Type="String">&#929;&#959;&#955;&#972;&#947;&#953;&#945; &#967;&#949;&#953;&#961;&#972;&#962;</Data></Cell>
  40.    </Row>
  41.    <Row>
  42.     <Cell ss:StyleID="s22"><Data ss:Type="String">Indication of the product:&#160;</Data></Cell>
  43.     <Cell ss:StyleID="s22"><Data ss:Type="String">&#922;&#949;&#966;&#945;&#955;&#972;&#966;&#969;&#957;&#945;</Data></Cell>
  44.    </Row>
  45.    <Row ss:AutoFitHeight="0">
  46.     <Cell ss:MergeAcross="1" ss:StyleID="s29"><Data ss:Type="String">en</Data></Cell>
  47.    </Row>
  48.    <Row>
  49.     <Cell ss:StyleID="s22"><Data ss:Type="String">Indication of the product:&#160;</Data></Cell>
  50.     <Cell ss:StyleID="s22"><Data ss:Type="String">Wrist watches</Data></Cell>
  51.    </Row>
  52.    <Row>
  53.     <Cell ss:StyleID="s22"><Data ss:Type="String">Indication of the product:&#160;</Data></Cell>
  54.     <Cell ss:StyleID="s22"><Data ss:Type="String">Headphones</Data></Cell>
  55.    </Row>
  56.    <Row ss:AutoFitHeight="0">
  57.     <Cell ss:MergeAcross="1" ss:StyleID="s29"><Data ss:Type="String">es</Data></Cell>
  58.    </Row>
  59.    <Row>
  60.     <Cell ss:StyleID="s22"><Data ss:Type="String">Indication of the product:&#160;</Data></Cell>
  61.     <Cell ss:StyleID="s22"><Data ss:Type="String">Relojes de pulsera</Data></Cell>
  62.    </Row>
  63.    <Row>
  64.     <Cell ss:StyleID="s22"><Data ss:Type="String">Indication of the product:&#160;</Data></Cell>
  65.     <Cell ss:StyleID="s22"><Data ss:Type="String">Auriculares de casco</Data></Cell>
  66.    </Row>
  67.    <Row ss:AutoFitHeight="0">
  68.     <Cell ss:MergeAcross="1" ss:StyleID="s29"><Data ss:Type="String">et</Data></Cell>
  69.    </Row>
  70.    <Row>
  71.     <Cell ss:StyleID="s22"><Data ss:Type="String">Indication of the product:&#160;</Data></Cell>
  72.     <Cell ss:StyleID="s22"><Data ss:Type="String">Käekellad</Data></Cell>
  73.    </Row>
  74.    <Row>
  75.     <Cell ss:StyleID="s22"><Data ss:Type="String">Indication of the product:&#160;</Data></Cell>
  76.     <Cell ss:StyleID="s22"><Data ss:Type="String">Kõrvaklapid</Data></Cell>
  77.    </Row>
  78.    <Row ss:AutoFitHeight="0">
  79.     <Cell ss:MergeAcross="1" ss:StyleID="s29"><Data ss:Type="String">fi</Data></Cell>
  80.    </Row>
  81.    <Row>
  82.     <Cell ss:StyleID="s22"><Data ss:Type="String">Indication of the product:&#160;</Data></Cell>
  83.     <Cell ss:StyleID="s22"><Data ss:Type="String">Rannekellot</Data></Cell>
  84.    </Row>
  85.    <Row>
  86.     <Cell ss:StyleID="s22"><Data ss:Type="String">Indication of the product:&#160;</Data></Cell>
  87.     <Cell ss:StyleID="s22"><Data ss:Type="String">Kuulokkeet</Data></Cell>
  88.    </Row>
  89.    <Row ss:AutoFitHeight="0">
  90.     <Cell ss:MergeAcross="1" ss:StyleID="s29"><Data ss:Type="String">fr</Data></Cell>
  91.    </Row>
  92.    <Row>
  93.     <Cell ss:StyleID="s22"><Data ss:Type="String">Indication of the product:&#160;</Data></Cell>
  94.     <Cell ss:StyleID="s22"><Data ss:Type="String">Montres-bracelets</Data></Cell>
  95.    </Row>
  96.    <Row>
  97.     <Cell ss:StyleID="s22"><Data ss:Type="String">Indication of the product:&#160;</Data></Cell>
  98.     <Cell ss:StyleID="s22"><Data ss:Type="String">Casques d'écoute</Data></Cell>
  99.    </Row>
  100.    <Row ss:AutoFitHeight="0">
  101.     <Cell ss:MergeAcross="1" ss:StyleID="s29"><Data ss:Type="String">hu</Data></Cell>
  102.    </Row>
  103.    <Row>
  104.     <Cell ss:StyleID="s22"><Data ss:Type="String">Indication of the product:&#160;</Data></Cell>
  105.     <Cell ss:StyleID="s22"><Data ss:Type="String">Karórák</Data></Cell>
  106.    </Row>


 
A l'aide d'un fichier XSL, je dois transformer ce fichier xml en un autre fichier xml, ne contenant que les infos qui m'interessent.
Le seul soucis, c'est que l'une des infos que je dois récupérer est le titre en anglais.
 
Il me faudrait donc un moyen pour recuperer le contenu des Cell just apres la ligne "en" sachant qu'il peut y avoir plus ou moins de langue, et plus ou moins de Cell pour chaque langue.
 
J'espere que vous avez compris mon probleme.
 
Merci

mood
Publicité
Posté le 12-12-2005 à 09:20:48  profilanswer
 

n°1264296
tellier
Posté le 12-12-2005 à 10:02:30  profilanswer
 

J'oubliais, j'aimerai savoir également si il y a possibilité de faire une boucle tant que en XSL

n°1265237
avander
Posté le 13-12-2005 à 10:30:56  profilanswer
 

Ton fichier xml manque de structure pour faire cela, je ne vois pas comment tu va déterminer la fin des articles après le 'en'...


Aller à :
Ajouter une réponse
  FORUM HardWare.fr
  Programmation
  XML/XSL

  [XSL]Une idee pour recuperer une info precise

 

Sujets relatifs
info date dans cookie[xml] récupérer tout le texte d'un élement ?
[Eclipse/CVS] Comment récupérer le nom de la branche avant le commit ?Récuperation d'info dans un forumlaire
récupérer une variable VBSCRIPT dans une page ASPrécupérer le code source page Web https..(dhtml, javascript) avec vba?
Récupérer les infos d'un fichier txt en batch[INFO] C99 TC1 & TC2 (DRAFT)
Récupérer le dernier post d'un sujetRécupérer le chemin d'un dossier cherché
Plus de sujets relatifs à : [XSL]Une idee pour recuperer une info precise


Copyright © 1997-2022 Hardware.fr SARL (Signaler un contenu illicite / Données personnelles) / Groupe LDLC / Shop HFR