Advertisement

10.17.2007 at 06:50PM PDT, ID: 22900761
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

7.6

Converting XML file to CSV

Asked by marcparillo in Extensible Markup Language (XML), Perl Programming Language, PHP Scripting Language

Tags: , , , ,

I've looked high and low for a PHP or Perl script that will take an XML file and turn it into a CSV or other delimited txt file.  It seems as if this XML file was created by Excel, but I can't import it into Excel and I can't figure out how to get it into a readable-usable form.

Thanks!

Here's my XML:
<?xml version="1.0"?>
<?mso-application progid="Excel.Sheet"?>
<Workbook xmlns="urn:schemas-microsoft-com:office:spreadsheet"
 xmlns:o="urn:schemas-microsoft-com:office:office"
 xmlns:x="urn:schemas-microsoft-com:office:excel"
 xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet"
 xmlns:html="http://www.w3.org/TR/REC-html40">
 <DocumentProperties xmlns="urn:schemas-microsoft-com:office:office">
  <LastAuthor>Me</LastAuthor>
  <Created>2006-02-27T19:24:51Z</Created>
  <Version>11.6568</Version>
 </DocumentProperties>
 <ExcelWorkbook xmlns="urn:schemas-microsoft-com:office:excel">
  <WindowHeight>6285</WindowHeight>
  <WindowWidth>11340</WindowWidth>
  <WindowTopX>360</WindowTopX>
  <WindowTopY>135</WindowTopY>
  <ProtectStructure>False</ProtectStructure>
  <ProtectWindows>False</ProtectWindows>
 </ExcelWorkbook>
 <Styles>
  <Style ss:ID="Default" ss:Name="Normal">
   <Alignment ss:Vertical="Bottom"/>
   <Borders/>
   <Font/>
   <Interior/>
   <NumberFormat/>
   <Protection/>
  </Style>
  <Style ss:ID="s21">
   <Interior/>
  </Style>
  <Style ss:ID="s22">
   <Font x:Family="Swiss" ss:Color="#FF0000"/>
   <Interior/>
  </Style>
 </Styles>
 <Worksheet ss:Name="_combind">
  <Table ss:ExpandedColumnCount="15" ss:ExpandedRowCount="1326" x:FullColumns="1"
   x:FullRows="1" ss:StyleID="s21">
   <Column ss:StyleID="s21" ss:Width="141"/>
   <Column ss:Index="8" ss:StyleID="s21" ss:Width="194.25"/>
   <Column ss:StyleID="s21" ss:Width="192"/>
   <Column ss:Index="15" ss:StyleID="s21" ss:Width="192"/>
   <Row>
    <Cell><Data ss:Type="String">Full Name (Name Field)</Data></Cell>
    <Cell><Data ss:Type="String">Title</Data></Cell>
    <Cell><Data ss:Type="String">Salutation</Data></Cell>
    <Cell><Data ss:Type="String">Nickname</Data></Cell>
    <Cell><Data ss:Type="String">Last Name</Data></Cell>
    <Cell><Data ss:Type="String">First Name</Data></Cell>
    <Cell><Data ss:Type="String">Middle Initial</Data></Cell>
    <Cell><Data ss:Type="String">Office Name for Address</Data></Cell>
    <Cell><Data ss:Type="String">Member E-mail</Data></Cell>
    <Cell><Data ss:Type="String">Care of</Data></Cell>
    <Cell><Data ss:Type="String">Address</Data></Cell>
    <Cell><Data ss:Type="String">City</Data></Cell>
    <Cell><Data ss:Type="String">State</Data></Cell>
    <Cell><Data ss:Type="String">Zip</Data></Cell>
    <Cell><Data ss:Type="String">E-mail</Data></Cell>
   </Row>
   <Row ss:Hidden="1">
    <Cell><Data ss:Type="String">Gloria</Data></Cell>
    <Cell><Data ss:Type="String">Ms. </Data></Cell>
    <Cell><Data ss:Type="String">Smith</Data></Cell>
    <Cell><Data ss:Type="String">Gloria</Data></Cell>
    <Cell><Data ss:Type="String">Smith</Data></Cell>
    <Cell><Data ss:Type="String">Gloria</Data></Cell>
    <Cell><Data ss:Type="String">R</Data></Cell>
    <Cell><Data ss:Type="String">PROPERTIES</Data></Cell>
    <Cell><Data ss:Type="String">myemail@email.com</Data></Cell>
    <Cell ss:Index="11"><Data ss:Type="String">400 Penn</Data></Cell>
    <Cell><Data ss:Type="String">Whitsett</Data></Cell>
    <Cell><Data ss:Type="String">State</Data></Cell>
    <Cell><Data ss:Type="Number">27111</Data></Cell>
    <Cell><Data ss:Type="String">myemail@email.com</Data></Cell>
   </Row>
    </Table>
  <WorksheetOptions xmlns="urn:schemas-microsoft-com:office:excel">
   <Print>
    <ValidPrinterInfo/>
    <HorizontalResolution>-1</HorizontalResolution>
    <VerticalResolution>0</VerticalResolution>
   </Print>
   <Selected/>
   <TopRowVisible>62</TopRowVisible>
   <Panes>
    <Pane>
     <Number>3</Number>
     <ActiveRow>91</ActiveRow>
     <ActiveCol>5</ActiveCol>
    </Pane>
   </Panes>
   <ProtectObjects>False</ProtectObjects>
   <ProtectScenarios>False</ProtectScenarios>
  </WorksheetOptions>
  <Sorting xmlns="urn:schemas-microsoft-com:office:excel">
   <Sort>Last Name</Sort>
  </Sorting>
 </Worksheet>
</Workbook>
Start Free Trial
[+][-]10.17.2007 at 07:02PM PDT, ID: 20098363

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]10.17.2007 at 07:28PM PDT, ID: 20098465

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]10.18.2007 at 01:19AM PDT, ID: 20099339

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]10.18.2007 at 04:56AM PDT, ID: 20100000

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zones: Extensible Markup Language (XML), Perl Programming Language, PHP Scripting Language
Tags: xml, csv, perl, convert, file
Sign Up Now!
Solution Provided By: mjcoyne
Participating Experts: 3
Solution Grade: A
 
 
[+][-]10.18.2007 at 06:25AM PDT, ID: 20100756

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]10.18.2007 at 08:00AM PDT, ID: 20101549

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]10.18.2007 at 08:46AM PDT, ID: 20101988

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32 / EE_QW_2_20070628