Example of applying CSS to convert XML documents

Source: Internet
Author: User
When you use CSS to convert an XML document, the syntax format of the link CSS style file is as follows: syntax: 1 Introduction

When CSS is used to convert an XML document, the syntax format of the link CSS style file is as follows:

Syntax:

 

This statement is used to reference an external CSS file to format and output XML documents.

2. apply CSS to convert XML documents

Apply the CSS style in the instance to format and output the XML document.

Code 3

CATALOG{background-color: #ffffff;width: 100%;}CD{display: block;margin-bottom: 30pt;margin-left: 0;}TITLE{color: #FF0000;font-size: 20pt;}ARTIST{color: #0000FF;font-size: 20pt;}COUNTRY,PRICE,YEAR,COMPANY{display: block;color: #000000;margin-left: 20pt;}

2. XML code:

 
 
 
  
   Empire BurlesqueBob Dylan
   
    USA
   
   
    Columbia
   
   
    10.90
   
   
    1985
   
  
  
   Hide your heartBonnie Tyler
   
    UK
   
   
    CBS Records
   
   
    9.90
   
   
    1988
   
  
 

IV. running results

The above is a detailed introduction of the example of applying CSS to the XML document. For more information, see other related articles in the first PHP community!

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.