Jump to content

Problems Transforming XML to XHTML Using XSL


driv4r
 Share

Recommended Posts

Hi everyone, that's my first post here, so please don't kill me if I make noob mistakes! :) I wanted to post it about 2 days ago but had to wait to get validated at first and didn't have time yesterday.Anyway, the problem is that I can't transform a table (spreadsheet saved as XML file) that I need to publish on my website to a XHTML file and therefore can't publish it. Well, I had a simple text list at first but I thought I'd make a nice table (XLS file) and then saved it as XML file.When trying to transform the XML file to XHTML using my own XSL file, I either get an empty table with the table headings from my XSL or all the data that I have in the XML file but without any modifying (just a wall of text and no tables or anything whatsoever).Here's the XML file I am trying to transform:

<?xml version="1.0" encoding="UTF-8"?><?xml-stylesheet type="text/xsl" href="Gran_Turismo_5_Car_List.xsl"?><?mso-application progid="Excel.Sheet"?><Workbook xmlns:c="urn:schemas-microsoft-com:office:component:spreadsheet" xmlns:html="http://www.w3.org/TR/REC-html40" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="urn:schemas-microsoft-com:office:spreadsheet" xmlns:x2="http://schemas.microsoft.com/office/excel/2003/xml" xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet" xmlns:x="urn:schemas-microsoft-com:office:excel"><OfficeDocumentSettings xmlns="urn:schemas-microsoft-com:office:office"><Colors><Color><Index>3</Index><RGB>#c0c0c0</RGB></Color><Color><Index>4</Index><RGB>#ff0000</RGB></Color><Color><Index>5</Index><RGB>#ffd320</RGB></Color></Colors></OfficeDocumentSettings><ExcelWorkbook xmlns="urn:schemas-microsoft-com:office:excel"><WindowHeight>9000</WindowHeight><WindowWidth>13860</WindowWidth><WindowTopX>240</WindowTopX><WindowTopY>75</WindowTopY><ProtectStructure>False</ProtectStructure><ProtectWindows>False</ProtectWindows></ExcelWorkbook><Styles><Style ss:ID="Default" ss:Name="Default"><Font ss:FontName="Arial1"/></Style><Style ss:ID="Result" ss:Name="Result"><Font ss:Bold="1" ss:FontName="Arial1" ss:Italic="1" ss:Underline="Single"/></Style><Style ss:ID="Result2" ss:Name="Result2"><Font ss:Bold="1" ss:FontName="Arial1" ss:Italic="1" ss:Underline="Single"/><NumberFormat ss:Format="Currency"/></Style><Style ss:ID="Heading" ss:Name="Heading"><Font ss:Bold="1" ss:FontName="Arial1" ss:Italic="1" ss:Size="16"/></Style><Style ss:ID="Heading1" ss:Name="Heading1"><Alignment ss:Rotate="90"/><Font ss:Bold="1" ss:FontName="Arial1" ss:Italic="1" ss:Size="16"/></Style><Style ss:ID="Heading_20_1" ss:Name="Heading 1"><Alignment ss:Vertical="Automatic" ss:Rotate="0"/><Font ss:FontName="Mangal" ss:Size="10"/></Style><Style ss:ID="co1"/><Style ss:ID="co2"/><Style ss:ID="co3"/><Style ss:ID="co4"/><Style ss:ID="co5"/><Style ss:ID="co6"/><Style ss:ID="co7"/><Style ss:ID="ta1"/><Style ss:ID="ta2"/><Style ss:ID="ta3"/><Style ss:ID="ce1" ss:Parent="Heading_20_1"><Alignment ss:Horizontal="Left" ss:Vertical="Automatic" ss:Indent="0" ss:Rotate="0"/><Borders/><Font ss:Bold="1" ss:FontName="Arial1" ss:Italic="1" ss:Size="14"/><NumberFormat ss:Format="Fixed"/></Style><Style ss:ID="ce2"><Alignment ss:Horizontal="Left" ss:Vertical="Automatic" ss:Indent="0" ss:Rotate="0"/></Style><Style ss:ID="ce3"><Alignment ss:Horizontal="Left" ss:Vertical="Automatic" ss:Indent="0" ss:Rotate="0"/><Borders><Border ss:Position="Bottom" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Left" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Right" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Top" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/></Borders><Font ss:Bold="1" ss:FontName="Arial1" ss:Size="10"/></Style><Style ss:ID="ce4"><Alignment ss:Horizontal="Left" ss:Vertical="Automatic" ss:Indent="0" ss:Rotate="0"/><Borders><Border ss:Position="Bottom" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Left" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Right" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Top" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/></Borders></Style><Style ss:ID="ce5"><Alignment ss:Horizontal="Left" ss:Vertical="Automatic" ss:Indent="0" ss:Rotate="0"/><Borders><Border ss:Position="Bottom" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Left" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Right" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Top" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/></Borders><Interior ss:Color="#ffd320" ss:Pattern="Solid"/></Style><Style ss:ID="ce6"><Alignment ss:Vertical="Automatic" ss:Indent="0" ss:Rotate="0"/><Borders><Border ss:Position="Bottom" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Left" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Right" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Top" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/></Borders><Font ss:Bold="1" ss:FontName="Arial1" ss:Size="9"/></Style><Style ss:ID="ce7"><Borders><Border ss:Position="Bottom" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Left" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Right" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Top" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/></Borders></Style><Style ss:ID="ce8"><Borders><Border ss:Position="Bottom" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Left" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Right" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Top" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/></Borders><Font ss:FontName="Arial1" ss:Size="10"/><Interior ss:Color="#ffd320" ss:Pattern="Solid"/></Style><Style ss:ID="ce9"><Borders><Border ss:Position="Bottom" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Left" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Right" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Top" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/></Borders><Font ss:Bold="1" ss:FontName="Arial1" ss:Size="10"/></Style><Style ss:ID="ce10"><Borders><Border ss:Position="Bottom" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Left" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Right" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/><Border ss:Position="Top" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/></Borders><Font ss:FontName="Arial1" ss:Size="10"/><NumberFormat ss:Format="General"/></Style><Style ss:ID="ta_extref"/><Style ss:ID="T1"><Font ss:FontName="Arial1" ss:Size="8" ss:VerticalAlign="Subscript"/></Style><Style ss:ID="T2"><Font ss:FontName="Arial1" ss:Size="9" ss:VerticalAlign="Subscript"/></Style><Style ss:ID="T3"><Font ss:FontName="SimSun1" ss:Size="10" ss:VerticalAlign="Subscript"/></Style><Style ss:ID="T4"><Font ss:FontName="Arial1" ss:Size="10" ss:VerticalAlign="Subscript"/></Style><Style ss:ID="T5"><Font ss:FontName="Times New Roman" ss:Size="12" ss:VerticalAlign="Subscript"/></Style></Styles><test>test</test><ss:Worksheet ss:Name="Sheet1"><Table ss:StyleID="ta1"><Column ss:Width="29.85"/><Column ss:Width="54.26"/><Column ss:Width="107.74"/><Column ss:Width="494.76"/><Column ss:Width="550.6"/><Column ss:Width="316.2"/><Row ss:Height="17.66"><Cell ss:MergeAcross="3" ss:StyleID="ce1"><Data ss:Type="String">Gran Turismo 5 Car List</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell><Data ss:Type="String">   </Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:StyleID="ce3"><Data ss:Type="String">Nr</Data></Cell><Cell ss:StyleID="ce6"><Data ss:Type="String">Detail Type</Data></Cell><Cell ss:StyleID="ce9"><Data ss:Type="String">Manufacturer</Data></Cell><Cell ss:StyleID="ce9"><Data ss:Type="String">Model</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:StyleID="ce4"/><Cell ss:StyleID="ce7"/><Cell ss:StyleID="ce7"/><Cell ss:StyleID="ce7"/><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:StyleID="ce4"><Data ss:Type="Number">1</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">S</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">AC Cars</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">427 S/C '66</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:StyleID="ce4"><Data ss:Type="Number">2</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">S</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">Acura</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">CL 3.2 Type-S '01</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:StyleID="ce4"><Data ss:Type="Number">3</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">S</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">Acura</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">CL 3.2 Type-S '03</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:StyleID="ce4"><Data ss:Type="Number">4</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">S</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">Acura</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">DN-X Concept '02</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Index="9" ss:Height="12.84"><Cell ss:StyleID="ce4"><Data ss:Type="Number">5</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">S</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">Acura</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">HSC Concept '04</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:StyleID="ce4"><Data ss:Type="Number">6</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">S</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">Acura</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">INTEGRA TYPE R '01</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:StyleID="ce5"><Data ss:Type="Number">7</Data></Cell><Cell ss:StyleID="ce8"><Data ss:Type="String">P/S</Data></Cell><Cell ss:StyleID="ce8"><Data ss:Type="String">Acura</Data></Cell><Cell ss:StyleID="ce8"><Data ss:Type="String">NSX '91</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:StyleID="ce5"><Data ss:Type="Number">8</Data></Cell><Cell ss:StyleID="ce8"><Data ss:Type="String">P</Data></Cell><Cell ss:StyleID="ce8"><Data ss:Type="String">Acura</Data></Cell><Cell ss:StyleID="ce8"><Data ss:Type="String">NSX RM '91</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:StyleID="ce4"><Data ss:Type="Number">9</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">S</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">Acura</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">NSX '04</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:StyleID="ce4"><Data ss:Type="Number">10</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">S</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">Acura</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">NSX Coupe '97</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:StyleID="ce4"><Data ss:Type="Number">11</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">S</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">Acura</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">RSX Type-S '04</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:StyleID="ce5"><Data ss:Type="Number">12</Data></Cell><Cell ss:StyleID="ce8"><Data ss:Type="String">P</Data></Cell><Cell ss:StyleID="ce8"><Data ss:Type="String">AEM</Data></Cell><Cell ss:StyleID="ce8"><Data ss:Type="String">S2000 (SEMA Gran Turismo Awards 2005)</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Index="17" ss:Height="12.84"><Cell ss:StyleID="ce4"><Data ss:Type="Number">13</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">S</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">Alfa Romeo</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">147 2.0 TWIN SPARK '02</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:StyleID="ce4"><Data ss:Type="Number">14</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">S</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">Alfa Romeo</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">147 GTA '02</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:StyleID="ce5"><Data ss:Type="Number">15</Data></Cell><Cell ss:StyleID="ce8"><Data ss:Type="String">P</Data></Cell><Cell ss:StyleID="ce8"><Data ss:Type="String">Alfa Romeo</Data></Cell><Cell ss:StyleID="ce8"><Data ss:Type="String">147 TI 2.0 TWIN SPARK '06</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:StyleID="ce4"><Data ss:Type="Number">16</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">S</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">Alfa Romeo</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">155 2.5 V6 TI '93</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:StyleID="ce4"><Data ss:Type="Number">17</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">S</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">Alfa Romeo</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">156 2.5 V6 24V '98</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:StyleID="ce4"><Data ss:Type="Number">18</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">S</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">Alfa Romeo</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">166 2.5 V6 24V Sportronic '98</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:StyleID="ce5"><Data ss:Type="Number">19</Data></Cell><Cell ss:StyleID="ce8"><Data ss:Type="String">P</Data></Cell><Cell ss:StyleID="ce8"><Data ss:Type="String">Alfa Romeo</Data></Cell><Cell ss:StyleID="ce8"><Data ss:Type="String">8C Competizione '08</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:StyleID="ce5"><Data ss:Type="Number">20</Data></Cell><Cell ss:StyleID="ce8"><Data ss:Type="String">P</Data></Cell><Cell ss:StyleID="ce8"><Data ss:Type="String">Alfa Romeo</Data></Cell><Cell ss:StyleID="ce8"><Data ss:Type="String">Brera Sky Window 3.2 JTS Q4 '06</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Index="25" ss:Height="12.84"><Cell ss:StyleID="ce4"><Data ss:Type="Number">21</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">S</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">Alfa Romeo</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">Giulia Sprint GTA 1600 '65</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:StyleID="ce4"><Data ss:Type="Number">22</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">S</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">Alfa Romeo</Data></Cell><Cell ss:StyleID="ce7"><Data ss:Type="String">Giulia Sprint Speciale '63</Data></Cell><Cell ss:Index="6"/></Row><Row ss:Height="13.41"><Cell ss:StyleID="ce5"><Data ss:Type="Number">23</Data></Cell><Cell ss:StyleID="ce8"><Data ss:Type="String">P</Data></Cell>[- many pages long similar code -]<Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Height="12.84"><Cell ss:Index="6"/></Row><Row ss:Index="65536" ss:Height="12.84"><Cell ss:Index="6"/></Row></Table><x:WorksheetOptions/></ss:Worksheet><ss:Worksheet ss:Name="Sheet2"><Table ss:StyleID="ta2"><Column ss:Width="64.26"/><Row ss:Height="12.84"><Cell ss:Index="1"/></Row></Table><x:WorksheetOptions/></ss:Worksheet><ss:Worksheet ss:Name="Sheet3"><Table ss:StyleID="ta3"><Column ss:Width="64.26"/><Row ss:Height="12.84"><Cell ss:Index="1"/></Row></Table><x:WorksheetOptions/></ss:Worksheet></Workbook>

This XML was actually one single line but it was obviously very ugly and hard to read, so I formatted it a lil, which is a rather tedious job.And the XSL file I am using:

<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE xsl:transform  [	<!ENTITY nbsp   " ">	<!ENTITY copy   "©">	<!ENTITY reg    "®">	<!ENTITY trade  "™">	<!ENTITY mdash  "—">	<!ENTITY ldquo  "“">	<!ENTITY rdquo  "”"> 	<!ENTITY pound  "£">	<!ENTITY yen    "¥">	<!ENTITY euro   "€">]><xsl:transform version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns:html="http://www.w3.org/TR/REC-html40"><xsl:output method="html" encoding="utf-8" doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN" doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" /><xsl:template match="/">  <html xmlns="http://www.w3.org/1999/xhtml">    <head>      <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />      <title>Test</title>    </head>    <body>      <h2>Gran Turismo 5 Car List</h2>      <!--      <table border="1">        <tr>          <th>Nr</th>          <th>Detail Type</th>          <th>Manufacturer</th>          <th>Model</th>        </tr>        -->        <!-- <xsl:for-each select="Workbook/ss:Worksheet/Table/Row/Cell">        <tr>          <td><xsl:value-of select="Data" /></td>        </tr>        </xsl:for-each> -->        <!--        <xsl:for-each select="Root/List">        <tr>          <td><xsl:value-of select="Nr" /></td>          <td><xsl:value-of select="Detail_Type" /></td>          <td><xsl:value-of select="Manufacturer" /></td>          <td><xsl:value-of select="Model" /></td>          <td><xsl:value-of select="Data" /></td>        </tr>        </xsl:for-each>                <tr>        -->          <!-- <td><xsl:value-of select="Workbook/Worksheet/Table/Row/Cell/Data" /></td> -->          <!-- <td><xsl:value-of select="Workbook/ss:Worksheet/Table/Row/Cell/Data" /></td> -->          <!-- <td><xsl:value-of select="Workbook/OfficeDocumentSettings/Colors/Color/Index" /></td> -->          <!-- <td><xsl:value-of select="Workbook/ExcelWorkbook/WindowHeight" /></td> -->          <!-- <td><xsl:value-of select="ss:Worksheet/Table/Row/Cell/Data" /></td> -->          <!-- <td><xsl:value-of select="Worksheet/Table/Row/Cell/Data" /></td> -->        <!--        </tr>        <tr>          <td><xsl:value-of select="Root/List/Manufacturer" /></td>        </tr>      </table> -->      <xsl:apply-templates />    </body>  </html></xsl:template><!--<xsl:template match="List">  <xsl:apply-templates select="Nr" />  <xsl:apply-templates select="Detail_Type" />  <xsl:apply-templates select="Manufacturer" />  <xsl:apply-templates select="Model" /></xsl:template><xsl:template match="/">  <span style="color:blue">  <xsl:value-of select="." />  </span> </xsl:template> --><xsl:template match="Root">  <table border="1">    <tr>      <th>Nr</th>      <th>Detail Type</th>      <th>Manufacturer</th>      <th>Model</th>    </tr>    <!-- <xsl:for-each select="List"> -->    <tr>      <td><xsl:value-of select="List/Nr" /></td>      <td><xsl:value-of select="List/Detail_Type" /></td>      <td><xsl:value-of select="List/Manufacturer" /></td>      <td><xsl:value-of select="List/Model" /></td>    </tr>    <!-- </xsl:for-each> -->  </table></xsl:template><xsl:template match="Workbook">  <table border="1">    <tr>      <th>Nr</th>      <th>Detail Type</th>      <th>Manufacturer</th>      <th>Model</th>    </tr>    <!-- <xsl:for-each select="Workbook"> -->    <tr>      <td><xsl:value-of select="test" /></td>      <td><xsl:value-of select="test" /></td>      <td><xsl:value-of select="test" /></td>      <td><xsl:value-of select="Workbook/test" /></td>    </tr>    <!-- </xsl:for-each> -->  </table></xsl:template></xsl:transform>

Now I have to mention I have tested this XSL file with a short XML file I created just to test if it's working and it does work. So, I suspect the problem is either with the XML code or the compatibility of this particular XML and my XSL. I have tried editing both the XML and XSL files many times using everything I could think of.Why did I choose to use XML and XSL? Well, basically I have a huge list of 1031 items, so to use a normal XHTML code would be kinda stupid and take ages (entering <li>-s or <td>-s more than 1000 times etc.). So, I thought it would be easier to use sth else but boy oh boy how wrong I was. I spent literally tens of hours on trying to get it sorted with not much success.Any help would be appreciated!Cheers,driv4rP.S. Had to shorten the XML file a lot to post it here, otherwise my post was too long.

Link to comment
Share on other sites

please don't kill me if I make noob mistakes! :)
The only reason we might kill you for is thinking we'd kill you for that :)Anyway...The top of your XML reads:
<Workbook ...  xmlns="urn:schemas-microsoft-com:office:spreadsheet" ...>

This means that the Workbook element, as well as all elements in the XML without a prefix, are part of the urn:schemas-microsoft-com:office:spreadsheet namespace.You have correctly associated this namespace with a prefix in your XSLT... but you need to use it on all elements that are in this namespace, regardless of their prefix in the XML. This includes elements without a prefix in the XML... so, replace, for example:

<xsl:for-each select="Workbook/ss:Worksheet/Table/Row/Cell">

with

<xsl:for-each select="ss:Workbook/ss:Worksheet/ss:Table/ss:Row/ss:Cell">

and so on.BTW, I'd reccomend getting yourself a specialized XML editor... Dreamwaver is really poor on options for XML (yes, I know that's your editor... only Dreamwaver generates those entities in the XSLT file). Stylus Studio is the best from my experience, but there are many other good ones too. Most of them have one feature in particular you mentioned was tedious... automatically indent XML files.

Link to comment
Share on other sites

Thanks a lot for the answer boen_robot! :) It's really working now!! :) It's amazing how simple it actually was to solve the problem but at the same time there was no way I could have worked it out myself as I didn't know about this ss prefix (, though I did go through the W3C XML tutorial a couple of days ago, at least the main part of it).So, what does ss actually mean? And why does it need to be even in front of the elements that don't actually have ss in front of them in XML file (only Worksheet has in my case). I guess it's because all elements that are part of the namespace need this ss?Now that the big issue has been solved I need to figure out how to get the data spread out in different columns, i.e. Nr in Nr, Detail Type in Detail Type, Model in Model column and so on. It's not like in the tutorial examples as all this data including column headings is named 'Data' in my XML file, so it's actually quite difficult for me.Oh, btw, I downloaded the Stylus Studio trial but I can only use it 14 days. I guess I should find a free XML editor after it's finished in case I want to use more long XML files in the future.EDIT: To clarify, at the moment I am just getting all the data under one (or all) columns but I need to get Nr only in Nr column and so on.EDIT2: Ok, by now I have somehow got the first column (Nr) showing the right data. Detail Type, Manufacturer & Model are still messed.EDIT3: Here's the properly indented XML file:

<?xml version="1.0" encoding="UTF-8"?><?xml-stylesheet type="text/xsl" href="Gran_Turismo_5_Car_List.xsl"?><?mso-application progid="Excel.Sheet"?><Workbook xmlns:c="urn:schemas-microsoft-com:office:component:spreadsheet" xmlns:html="http://www.w3.org/TR/REC-html40" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"          xmlns="urn:schemas-microsoft-com:office:spreadsheet" xmlns:x2="http://schemas.microsoft.com/office/excel/2003/xml" xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet" xmlns:x="urn:schemas-microsoft-com:office:excel">	<OfficeDocumentSettings xmlns="urn:schemas-microsoft-com:office:office">		<Colors>			<Color>				<Index>3</Index>				<RGB>#c0c0c0</RGB>			</Color>			<Color>				<Index>4</Index>				<RGB>#ff0000</RGB>			</Color>			<Color>				<Index>5</Index>				<RGB>#ffd320</RGB>			</Color>		</Colors>	</OfficeDocumentSettings>	<ExcelWorkbook xmlns="urn:schemas-microsoft-com:office:excel">		<WindowHeight>9000</WindowHeight>		<WindowWidth>13860</WindowWidth>		<WindowTopX>240</WindowTopX>		<WindowTopY>75</WindowTopY>		<ProtectStructure>False</ProtectStructure>		<ProtectWindows>False</ProtectWindows>	</ExcelWorkbook>	<Styles>		<Style ss:ID="Default" ss:Name="Default">			<Font ss:FontName="Arial1"/>		</Style>		<Style ss:ID="Result" ss:Name="Result">			<Font ss:Bold="1" ss:FontName="Arial1" ss:Italic="1" ss:Underline="Single"/>		</Style>		<Style ss:ID="Result2" ss:Name="Result2">			<Font ss:Bold="1" ss:FontName="Arial1" ss:Italic="1" ss:Underline="Single"/>			<NumberFormat ss:Format="Currency"/>		</Style>		<Style ss:ID="Heading" ss:Name="Heading">			<Font ss:Bold="1" ss:FontName="Arial1" ss:Italic="1" ss:Size="16"/>		</Style>		<Style ss:ID="Heading1" ss:Name="Heading1">			<Alignment ss:Rotate="90"/>			<Font ss:Bold="1" ss:FontName="Arial1" ss:Italic="1" ss:Size="16"/>		</Style>		<Style ss:ID="Heading_20_1" ss:Name="Heading 1">			<Alignment ss:Vertical="Automatic" ss:Rotate="0"/>			<Font ss:FontName="Mangal" ss:Size="10"/>		</Style>		<Style ss:ID="co1"/>		<Style ss:ID="co2"/>		<Style ss:ID="co3"/>		<Style ss:ID="co4"/>		<Style ss:ID="co5"/>		<Style ss:ID="co6"/>		<Style ss:ID="co7"/>		<Style ss:ID="ta1"/>		<Style ss:ID="ta2"/>		<Style ss:ID="ta3"/>		<Style ss:ID="ce1" ss:Parent="Heading_20_1">			<Alignment ss:Horizontal="Left" ss:Vertical="Automatic" ss:Indent="0" ss:Rotate="0"/>			<Borders/>			<Font ss:Bold="1" ss:FontName="Arial1" ss:Italic="1" ss:Size="14"/>			<NumberFormat ss:Format="Fixed"/>		</Style>		<Style ss:ID="ce2">			<Alignment ss:Horizontal="Left" ss:Vertical="Automatic" ss:Indent="0" ss:Rotate="0"/>		</Style>		<Style ss:ID="ce3">			<Alignment ss:Horizontal="Left" ss:Vertical="Automatic" ss:Indent="0" ss:Rotate="0"/>			<Borders>				<Border ss:Position="Bottom" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Left" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Right" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Top" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>			</Borders>			<Font ss:Bold="1" ss:FontName="Arial1" ss:Size="10"/>		</Style>		<Style ss:ID="ce4">			<Alignment ss:Horizontal="Left" ss:Vertical="Automatic" ss:Indent="0" ss:Rotate="0"/>			<Borders>				<Border ss:Position="Bottom" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Left" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Right" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Top" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>			</Borders>		</Style>		<Style ss:ID="ce5">			<Alignment ss:Horizontal="Left" ss:Vertical="Automatic" ss:Indent="0" ss:Rotate="0"/>			<Borders>				<Border ss:Position="Bottom" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Left" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Right" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Top" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>			</Borders>			<Interior ss:Color="#ffd320" ss:Pattern="Solid"/>		</Style>		<Style ss:ID="ce6">			<Alignment ss:Vertical="Automatic" ss:Indent="0" ss:Rotate="0"/>			<Borders>				<Border ss:Position="Bottom" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Left" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Right" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Top" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>			</Borders>			<Font ss:Bold="1" ss:FontName="Arial1" ss:Size="9"/>		</Style>		<Style ss:ID="ce7">			<Borders>				<Border ss:Position="Bottom" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Left" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Right" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Top" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>			</Borders>		</Style>		<Style ss:ID="ce8">			<Borders>				<Border ss:Position="Bottom" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Left" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Right" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Top" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>			</Borders>			<Font ss:FontName="Arial1" ss:Size="10"/>			<Interior ss:Color="#ffd320" ss:Pattern="Solid"/>		</Style>		<Style ss:ID="ce9">			<Borders>				<Border ss:Position="Bottom" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Left" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Right" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Top" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>			</Borders>			<Font ss:Bold="1" ss:FontName="Arial1" ss:Size="10"/>		</Style>		<Style ss:ID="ce10">			<Borders>				<Border ss:Position="Bottom" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Left" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Right" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>				<Border ss:Position="Top" ss:LineStyle="Continuous" ss:Weight="1" ss:Color="#000000"/>			</Borders>			<Font ss:FontName="Arial1" ss:Size="10"/>			<NumberFormat ss:Format="General"/>		</Style>		<Style ss:ID="ta_extref"/>		<Style ss:ID="T1">			<Font ss:FontName="Arial1" ss:Size="8" ss:VerticalAlign="Subscript"/>		</Style>		<Style ss:ID="T2">			<Font ss:FontName="Arial1" ss:Size="9" ss:VerticalAlign="Subscript"/>		</Style>		<Style ss:ID="T3">			<Font ss:FontName="SimSun1" ss:Size="10" ss:VerticalAlign="Subscript"/>		</Style>		<Style ss:ID="T4">			<Font ss:FontName="Arial1" ss:Size="10" ss:VerticalAlign="Subscript"/>		</Style>		<Style ss:ID="T5">			<Font ss:FontName="Times New Roman" ss:Size="12" ss:VerticalAlign="Subscript"/>		</Style>	</Styles>	<ss:Worksheet ss:Name="Sheet1">		<Table ss:StyleID="ta1">			<Column ss:Width="29.85"/>			<Column ss:Width="54.26"/>			<Column ss:Width="107.74"/>			<Column ss:Width="494.76"/>			<Column ss:Width="550.6"/>			<Column ss:Width="316.2"/>			<Row ss:Height="17.66">				<Cell ss:MergeAcross="3" ss:StyleID="ce1">					<Data ss:Type="String">Gran Turismo 5 Car List</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell>					<Data ss:Type="String">					</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce3">					<Data ss:Type="String">Nr</Data>				</Cell>				<Cell ss:StyleID="ce6">					<Data ss:Type="String">Detail Type</Data>				</Cell>				<Cell ss:StyleID="ce9">					<Data ss:Type="String">Manufacturer</Data>				</Cell>				<Cell ss:StyleID="ce9">					<Data ss:Type="String">Model</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce4"/>				<Cell ss:StyleID="ce7"/>				<Cell ss:StyleID="ce7"/>				<Cell ss:StyleID="ce7"/>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce4">					<Data ss:Type="Number">1</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">S</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">AC Cars</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">427 S/C '66</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce4">					<Data ss:Type="Number">2</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">S</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Acura</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">CL 3.2 Type-S '01</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce4">					<Data ss:Type="Number">3</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">S</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Acura</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">CL 3.2 Type-S '03</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce4">					<Data ss:Type="Number">4</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">S</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Acura</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">DN-X Concept '02</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Index="9" ss:Height="12.84">				<Cell ss:StyleID="ce4">					<Data ss:Type="Number">5</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">S</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Acura</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">HSC Concept '04</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce4">					<Data ss:Type="Number">6</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">S</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Acura</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">INTEGRA TYPE R '01</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce5">					<Data ss:Type="Number">7</Data>				</Cell>				<Cell ss:StyleID="ce8">					<Data ss:Type="String">P/S</Data>				</Cell>				<Cell ss:StyleID="ce8">					<Data ss:Type="String">Acura</Data>				</Cell>				<Cell ss:StyleID="ce8">					<Data ss:Type="String">NSX '91</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce5">					<Data ss:Type="Number">8</Data>				</Cell>				<Cell ss:StyleID="ce8">					<Data ss:Type="String">P</Data>				</Cell>				<Cell ss:StyleID="ce8">					<Data ss:Type="String">Acura</Data>				</Cell>				<Cell ss:StyleID="ce8">					<Data ss:Type="String">NSX RM '91</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce4">					<Data ss:Type="Number">9</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">S</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Acura</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">NSX '04</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce4">					<Data ss:Type="Number">10</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">S</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Acura</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">NSX Coupe '97</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce4">					<Data ss:Type="Number">11</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">S</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Acura</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">RSX Type-S '04</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce5">					<Data ss:Type="Number">12</Data>				</Cell>				<Cell ss:StyleID="ce8">					<Data ss:Type="String">P</Data>				</Cell>				<Cell ss:StyleID="ce8">					<Data ss:Type="String">AEM</Data>				</Cell>				<Cell ss:StyleID="ce8">					<Data ss:Type="String">S2000 (SEMA Gran Turismo Awards 2005)</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Index="17" ss:Height="12.84">				<Cell ss:StyleID="ce4">					<Data ss:Type="Number">13</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">S</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Alfa Romeo</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">147 2.0 TWIN SPARK '02</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce4">					<Data ss:Type="Number">14</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">S</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Alfa Romeo</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">147 GTA '02</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce5">					<Data ss:Type="Number">15</Data>				</Cell>				<Cell ss:StyleID="ce8">					<Data ss:Type="String">P</Data>				</Cell>				<Cell ss:StyleID="ce8">					<Data ss:Type="String">Alfa Romeo</Data>				</Cell>				<Cell ss:StyleID="ce8">					<Data ss:Type="String">147 TI 2.0 TWIN SPARK '06</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce4">					<Data ss:Type="Number">16</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">S</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Alfa Romeo</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">155 2.5 V6 TI '93</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce4">					<Data ss:Type="Number">17</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">S</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Alfa Romeo</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">156 2.5 V6 24V '98</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce4">					<Data ss:Type="Number">18</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">S</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Alfa Romeo</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">166 2.5 V6 24V Sportronic '98</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce5">					<Data ss:Type="Number">19</Data>				</Cell>				<Cell ss:StyleID="ce8">					<Data ss:Type="String">P</Data>				</Cell>				<Cell ss:StyleID="ce8">					<Data ss:Type="String">Alfa Romeo</Data>				</Cell>				<Cell ss:StyleID="ce8">					<Data ss:Type="String">8C Competizione '08</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce5">					<Data ss:Type="Number">20</Data>				</Cell>				<Cell ss:StyleID="ce8">					<Data ss:Type="String">P</Data>				</Cell>				<Cell ss:StyleID="ce8">					<Data ss:Type="String">Alfa Romeo</Data>				</Cell>				<Cell ss:StyleID="ce8">					<Data ss:Type="String">Brera Sky Window 3.2 JTS Q4 '06</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Index="25" ss:Height="12.84">				<Cell ss:StyleID="ce4">					<Data ss:Type="Number">21</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">S</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Alfa Romeo</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Giulia Sprint GTA 1600 '65</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce4">					<Data ss:Type="Number">22</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">S</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Alfa Romeo</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Giulia Sprint Speciale '63</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="13.41">				<Cell ss:StyleID="ce5">					<Data ss:Type="Number">23</Data>				</Cell>				<Cell ss:StyleID="ce8">					<Data ss:Type="String">P</Data>				</Cell>				<Cell ss:StyleID="ce8">					<Data ss:Type="String">Alfa Romeo</Data>				</Cell>				<Cell ss:StyleID="ce8">					<ss:Data xmlns="http://www.w3.org/TR/REC-html40" ss:Type="String">GIULIA TZ2 carrozzata da ZAGATO CN.AR750106 '65 <Font html:Face="Arial1" html:Size="8">(Pebble Beach Concours d'Elegance Gran Turismo Trophy 2009)</Font></ss:Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce4">					<Data ss:Type="Number">24</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">S</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Alfa Romeo</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">GT 3.2 V6 24V '04</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce4">					<Data ss:Type="Number">25</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">S</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Alfa Romeo</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">GTV 3.0 V6 24V '01</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce4">					<Data ss:Type="Number">26</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">S</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Alfa Romeo</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Spider 3.0i V6 24V '01</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>			<Row ss:Height="12.84">				<Cell ss:StyleID="ce4">					<Data ss:Type="Number">27</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">S</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Alfa Romeo</Data>				</Cell>				<Cell ss:StyleID="ce7">					<Data ss:Type="String">Spider 1600 Duetto '66</Data>				</Cell>				<Cell ss:Index="6"/>			</Row>[- Removed a huge chunk of post from here to get the post short enough -]			<!-- Removed hundreds of rows like this:			<Row ss:Height="12.84">				<Cell ss:Index="6"/>			</Row>			from here -->			<Row ss:Index="65536" ss:Height="12.84">				<Cell ss:Index="6"/>			</Row>		</Table>		<x:WorksheetOptions/>	</ss:Worksheet>	<ss:Worksheet ss:Name="Sheet2">		<Table ss:StyleID="ta2">			<Column ss:Width="64.26"/>			<Row ss:Height="12.84">				<Cell ss:Index="1"/>			</Row>		</Table>		<x:WorksheetOptions/>	</ss:Worksheet>	<ss:Worksheet ss:Name="Sheet3">		<Table ss:StyleID="ta3">			<Column ss:Width="64.26"/>			<Row ss:Height="12.84">				<Cell ss:Index="1"/>			</Row>		</Table>		<x:WorksheetOptions/>	</ss:Worksheet></Workbook>

EDIT 4: Awesome, just got the Model column working as well, so only Detail Type and Manufacturer to sort out now! :) And I think I might know how to do it but I better get some sleep soon and carry on tomorrow.

Edited by driv4r
Link to comment
Share on other sites

Compliant XPath implementations (and in turn - XSLT) don't read your document as having a name with or without a prefix... they read it as an element with a name in a certain namespace.

<Workbook>

means this element and all of its descendants without a prefix are not in a namespace.

<Workbook ...  xmlns="urn:schemas-microsoft-com:office:spreadsheet" ...>

means this element and all of its descendants without a prefix are in the "urn:schemas-microsoft-com:office:spreadsheet" namespace. The XML parser reads this element as

{urn:schemas-microsoft-com:office:spreadsheet}Workbook

(WARNING: Pseudo notation, just to illustrate the point)

<ss:Workbook ...  xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet" ...>

means this element, and all of its descendants with a prefix of "ss" are in the "urn:schemas-microsoft-com:office:spreadsheet" namespace. The XML parser reads this element too as

{urn:schemas-microsoft-com:office:spreadsheet}Workbook

So... how does XSLT (or, XPath in particular) disambigue between elements in the "urn:schemas-microsoft-com:office:spreadsheet" namespace and elements not in a namespace? It doesn't... you explicitly map a new set of prefixes to namespaces, and use them in the XPath expressions to say what kind of an element you are after.

And I think I might know how to do it but I better get some sleep soon and carry on tomorrow.
It's always exciting when the solution seems so close, yet so far :) .
Link to comment
Share on other sites

Great, all the columns are sorted and this time it was actually quite easy as I was right in saying that I think I might know how to get it sorted earlier! :) Here's my master code:

<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE xsl:transform  [	<!ENTITY nbsp   " ">	<!ENTITY copy   "©">	<!ENTITY reg    "®">	<!ENTITY trade  "™">	<!ENTITY mdash  "—">	<!ENTITY ldquo  "“">	<!ENTITY rdquo  "”"> 	<!ENTITY pound  "£">	<!ENTITY yen    "¥">	<!ENTITY euro   "€">]><xsl:transform version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns:html="http://www.w3.org/TR/REC-html40"><xsl:output method="html" encoding="utf-8" doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN" doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" /><xsl:template match="/">  <html xmlns="http://www.w3.org/1999/xhtml">    <head>      <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />      <title>Test</title>    </head>    <body>      <h2>Gran Turismo 5 Car List</h2>      <table border="3">        <tr>          <th>Nr</th>          <th>Detail Type</th>          <th>Manufacturer</th>          <th>Model</th>        </tr>        <xsl:for-each select="ss:Workbook/ss:Worksheet/ss:Table/ss:Row[position()>=4]">        <tr>          <td><xsl:value-of select="ss:Cell[position()>=1]" /></td>          <td><xsl:value-of select="ss:Cell[position()>=2]" /></td>          <td><xsl:value-of select="ss:Cell[position()>=3]" /></td>          <td><xsl:value-of select="ss:Cell[position()>=4]" /></td>        </tr>        </xsl:for-each>      </table>      <!-- <xsl:apply-templates /> -->    </body>  </html></xsl:template><!-- <xsl:template match="List">  <xsl:apply-templates select="Nr" />  <xsl:apply-templates select="Detail_Type" />  <xsl:apply-templates select="Manufacturer" />  <xsl:apply-templates select="Model" /></xsl:template><xsl:template match="/">  <span style="color:blue">  <xsl:value-of select="." />  </span> </xsl:template><xsl:template match="Root">  <table border="1">    <tr>      <th>Nr</th>      <th>Detail Type</th>      <th>Manufacturer</th>      <th>Model</th>    </tr>    <xsl:for-each select="List">    <tr>      <td><xsl:value-of select="List/Nr" /></td>      <td><xsl:value-of select="List/Detail_Type" /></td>      <td><xsl:value-of select="List/Manufacturer" /></td>      <td><xsl:value-of select="List/Model" /></td>    </tr>    </xsl:for-each>  </table></xsl:template><xsl:template match="ss:Workbook">  <table border="1">    <tr>      <th>Nr</th>      <th>Detail Type</th>      <th>Manufacturer</th>      <th>Model</th>    </tr>    <xsl:for-each select="Workbook">    <tr>      <td><xsl:value-of select="ss:test" /></td>      <td><xsl:value-of select="ss:Worksheet/ss:Table/ss:Row/ss:Cell/ss:Data" /></td>      <td><xsl:value-of select="ss:Worksheet/ss:Table/ss:Row/ss:Cell/ss:Data" /></td>      <td><xsl:value-of select="ss:Worksheet/ss:Table/ss:Row/ss:Cell/ss:Data" /></td>    </tr>    </xsl:for-each>  </table></xsl:template>--></xsl:transform>

Nah, it's nothing special but for me personally it's almost perfect!Anyway, now I want to sort out only one thing with this now nice-looking table. Colours. In my XLS spreadsheet I had changed the background colour of some of the rows but that is not showing up now.So, I have one more question...I can't explain it very well but basically is it possible to get those coloured rows from XML file showing up or do I need to write completely new code for setting colours for rows in the XSL file?Also, if those colours that are mentioned inside the XML file can't be used at all then it doesn't even make sense that they are there and I should remove them because my XML file is huge (430KB) and I don't want that people with slower internet connections suffer or leave my website because of that.EDIT: After minor tweaks the first version of it has finally been uploaded and published on my website here: Gran Turismo 5 Car List. For now I have left the colours out but will add them later on in one way or another...EDIT2: Got the colours sorted as well in the morning before going to bed today, so it's pretty much perfect now, I'm defo happy with the result :) I'm not happy with the amount of time spent on it though.

Edited by driv4r
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...