Menu
×
   ❮     
HTML CSS JAVASCRIPT SQL PYTHON JAVA PHP HOW TO W3.CSS C C++ C# BOOTSTRAP REACT MYSQL JQUERY EXCEL XML DJANGO NUMPY PANDAS NODEJS R TYPESCRIPT ANGULAR GIT POSTGRESQL MONGODB ASP AI GO KOTLIN SASS VUE DSA GEN AI SCIPY AWS CYBERSECURITY DATA SCIENCE
     ❯   

什么是 XML?


HTML

XML 代表可扩展标记语言

XML 在许多不同的 IT 系统中发挥着重要作用

XML 通常用于在互联网上分发数据

对于所有网页开发者来说,了解 XML 是非常重要的


XML 示例 1

<?xml version="1.0" encoding="UTF-8"?>
<note>
  <to>Tove</to>
  <from>Jani</from>
  <heading>提醒</heading>
  <body>这个周末别忘了我!</body>
</note>

显示 XML 文件 » 以便签形式显示 XML 文件 »

×

XML 示例 2

<?xml version="1.0" encoding="UTF-8"?>
<breakfast_menu>
<food>
    <name>比利时华夫饼</name>
    <price>$5.95</price>
    <description>
   两份我们著名的比利时华夫饼,配上大量真正的枫糖浆
   </description>
    <calories>650</calories>
</food>
<food>
    <name>草莓比利时华夫饼</name>
    <price>$7.95</price>
    <description>
    覆盖着草莓和鲜奶油的轻盈比利时华夫饼
    </description>
    <calories>900</calories>
</food>
<food>
    <name>浆果比利时华夫饼</name>
    <price>$8.95</price>
    <description>
    覆盖着各种新鲜浆果和鲜奶油的比利时华夫饼
    </description>
    <calories>900</calories>
</food>
<food>
    <name>法式吐司</name>
    <price>$4.50</price>
    <description>
    厚切片,采用我们自制的酸面包制成
    </description>
    <calories>600</calories>
</food>
<food>
    <name>家常早餐</name>
    <price>$6.95</price>
    <description>
    两枚鸡蛋,培根或香肠,吐司,以及我们广受欢迎的土豆泥
    </description>
    <calories>950</calories>
</food>
</breakfast_menu>

显示 XML 文件 » 打开 XML 文件 » 用 XSLT 显示 »

×

标题


完整 XML 教程

这是一篇关于 XML 的简短介绍。

如需完整的 XML 教程,请访问 W3Schools XML 教程.


×

Contact Sales

If you want to use W3Schools services as an educational institution, team or enterprise, send us an e-mail:
[email protected]

Report Error

If you want to report an error, or if you want to make a suggestion, send us an e-mail:
[email protected]

W3Schools is optimized for learning and training. Examples might be simplified to improve reading and learning. Tutorials, references, and examples are constantly reviewed to avoid errors, but we cannot warrant full correctness of all content. While using W3Schools, you agree to have read and accepted our terms of use, cookie and privacy policy.

Copyright 1999-2024 by Refsnes Data. All Rights Reserved. W3Schools is Powered by W3.CSS.