You are on page 1of 2

<?xml version="1.0" encoding="utf-8"?

>
<?xml-stylesheet type="text/css" href="style_xml.css"?>
<!DOCTYPE note
[
<!ELEMENT root (name)>
<!ELEMENT name (value, category, carbohydrates, fiber, fat, energy)>
<!ELEMENT value (#PCDATA)>
<!ELEMENT category (#PCDATA)>
<!ELEMENT carbohydrate (#PCDATA)>
<!ELEMENT fibre (#PCDATA)>
<!ELEMENT fat (#PCDATA)>
<!ELEMENT energy (#PCDATA)>
]>
<root
xmlns="http://www.w3schools.com"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="assign4.xsd">
<name>
<value>
banana
</value>
<category>
fruit
</category>
<carbohydrates>20</carbohydrates>
<fat>40</fat>
<fibre>30</fibre>
<energy>200</energy>
</name>
<br />
<name>
<value>
tomato
</value>
<category>
vegetable
</category>
<carbohydrates>20</carbohydrates>
<fat>40</fat>
<fibre>30</fibre>
<energy>200</energy>
</name>
<name>
<value>
gadbad
</value>
<category>
desert
</category>
<carbohydrates>20</carbohydrates>
<fat>40</fat>
<fibre>30</fibre>
<energy>200</energy>
</name>
<name>
<value>
milk
</value>
<category>
dairy
</category>
<carbohydrates>20</carbohydrates>
<fat>40</fat>
<fibre>30</fibre>
<energy>200</energy>
</name>
<name>
<value>
wheat
</value>
<category>
grain
</category>
<carbohydrates>20</carbohydrates>
<fat>40</fat>
<fibre>30</fibre>
<energy>200</energy>
</name>
</root>

You might also like