Convert XML into EXECL

Source: Internet
Author: User
XML conversion to execl I want to convert the XML file generated by PHP to execl table representation & nbsp; for example, my xml is XMLcode & lt; subject & gt; BasicInformation & lt; question & gt; Whatisyourage? & Lt; answer & gt; 8-12 & lt; answer & gt; & lt; convert XML to EXECL
I want to convert the XML file generated in PHP to execl table representation.
For example, my xml is
XML code
   
  
     Basic Information  
   
      What is your age?   8-12   
    
     2
       
    
     0.01%
       13-19   
    
     43
       
    
     0.31%
       20-34   
    
     65
       
    
     0.47%
       35-49   
    
     24
       
    
     0.18%
       50+   
    
     3
       
    
     0.02%
       
   
   
      What is your gender?   Male   
    
     119
       
    
     0.87%
       Female   
    
     18
       
    
     0.13%
       
   
  

When this sub-statement is represented in EXECL
Only the last layer of data is displayed, that is, answer count and ratio. the content of question is not displayed, and the answer count ratio data is not in the corresponding row.
How can I display XML data properly under the guidance of a person?

------ Solution --------------------
Your code?
------ Solution --------------------
EXECL has its own format. you can only convert it to execl format to open it.
------ Solution --------------------
Phpwind splits the xmlfield, and then the output x.csv can be opened in excel.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.