Web Technologies
XML
Smt.M.Jeevana Sujitha
Assistant Professor
Department of Computer Science and Engineering
SRKR Engineering College, Bhimavaram, A.P. - 534204
OBJECTIVES
The Objectives of this lecture are
XML
XML
Difference between HTML & XML:
XML
Elements and Attributes:
Syntax:
<element-name> content </element-name>
Example:
<person>
<person-info>
<name>srinu</name>
<city>palakollu</city>
</person-info>
<hobby>
<first>Reading news paper</first>
<second>Playing cricket</second>
</hobby>
</person>
XML
Rules for writing XML document:
Example: <hobby> painting
<one>
<two> srinu</one>
</two>
XML
Rules for writing XML document:
name or in attribute name.
Example: <per son> srinu </per son>
single quote.
Example: <person flag=“true”> </person>
meanings.
Example:
< for lessthan
> for greater than & for ampersand " for double quotes
Comments in XML document:
XML
Syntax:
<!–- This is comment line -->
XML
Namespace in XML:
Example:
<File-description>
<text fname=“input.txt”>
<describe> It is text file</describe>
</text>
<text fname=“flower.jpg”>
<describe> It is an image file</describe>
</text>
<File-description>
Advantages of XML:
XML
THANK YOU