By GokiSoft.com|
19:36 25/03/2024|
XML
[Share Code] Tỉm hiểu XML bài 1
#student-list2.xml
<?xml version="1.0" encoding="UTF-8"?>
<StudentList xmlns:s1="https://gokisoft.com/aptech-ltn">
<s1:Student xmlns:s1="https://gokisoft.com/aptech" xmlns:s2="https://gokisoft.com/c2307l">
<s1:Fullname>TRAN VAN A</s1:Fullname>
<s2:Address>Ha Noi</s2:Address>
<s1:Email>tranvana@gmail.com</s1:Email>
<s2:Gender>Male</s2:Gender>
</s1:Student>
<Student xmlns:s1="https://gokisoft.com/aptech" xmlns="https://gokisoft.com/default">
<Fullname><![CDATA[TRAN VAN B <> sdjh &^*76sd]]></Fullname>
<s1:Address>Ha Noi</s1:Address>
<Email>tranvanb@gmail.com</Email>
<Gender>Male</Gender>
</Student>
<Student>
<Fullname>TRAN VAN C</Fullname>
<Address>Ha Noi</Address>
<Email>tranvanc@gmail.com</Email>
<Gender>Male</Gender>
</Student>
</StudentList>
#student.xml
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE Student [
<!ELEMENT Student (Fullname, Address, Email, Gender)>
<!ELEMENT Fullname (#PCDATA)>
<!ELEMENT Address (#PCDATA)>
<!ELEMENT Email (#PCDATA)>
<!ELEMENT Gender (#PCDATA)>
<!ENTITY TVD 'TRAN VAN DIEP'>
]>
<Student>
<!-- Mo ta ten nguoi dung -->
<Fullname>TRAN VAN A > &TVD;</Fullname>
<!-- Dia chi nguoi dung -->
<Address>Ha Noi</Address>
<Email>tranvana@gmail.com</Email>
<Gender>Male &TVD;</Gender>
</Student>
#student-list.xml
<?xml version="1.0" encoding="UTF-8"?>
<StudentList>
<Student>
<Fullname>TRAN VAN A</Fullname>
<Address>Ha Noi</Address>
<Email>tranvana@gmail.com</Email>
<Gender>Male</Gender>
</Student>
<Student>
<Fullname><![CDATA[TRAN VAN B <> sdjh &^*76sd]]></Fullname>
<Address>Ha Noi</Address>
<Email>tranvanb@gmail.com</Email>
<Gender>Male</Gender>
</Student>
<Student>
<Fullname>TRAN VAN C</Fullname>
<Address>Ha Noi</Address>
<Email>tranvanc@gmail.com</Email>
<Gender>Male</Gender>
</Student>
</StudentList>
#student.html
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>HTML Tutorial</title>
</head>
<body>
<ul>
<li style="color: red">Fullname: TRAN VAN A</li>
<li>Address: Ha Noi</li>
<li>Email: tranvana@gmail.com</li>
<li>Gender: Male</li>
</ul>
<abc style="mau: red; co-chu: 30px;">Xin chao</abc>
</body>
</html>
#readme.txt
Nội dung:
- XML
- Là gì?
- Tại sao học
- Viết tài liệu XML chuẩn
- Ứng dụng trong dự án -> ???
- JSON
- Là gì?
- Viết tài liệu JSON chuẩn
- Ứng dụng trong dự án
- Viết API
- Sử dụng php tạo API sử dụng trong dự án
=======================================================================
Tags:
Phản hồi từ học viên
5
(Dựa trên đánh giá ngày hôm nay)