Export High-Res PDF
Switch to Light Mode
SkillSnap Official GuideUpdated 7/24/2026
XML
The universal markup standard. Master XSD validation, XPath querying, and critical security defenses against XXE attacks.
Core Syntax & Rules
Strict closing tags mandatory<tag>...</tag>
<Tag> != <tag>Case Sensitivity
Document must have exactly one rootRoot Element
<?xml version="1.0" encoding="UTF-8"?>Prolog
Escape special characters (<, &)< &
Structure: Elements vs Attributes
Use for core data & lists (Multiple items)Element
Use for metadata (IDs, types, lang)Attribute
Namespace to avoid name collisionsxmlns
Include raw text without escapingCDATA
Validation (XSD)
Support for strong types (int, date)XSD over DTD
Match xmlns in instance documenttargetNamespace
Enforce element order & constraintsSequence / Choice
Make fields mandatoryminOccurs="1"
Querying & Transformation
Absolute path selection (XPath)/root/child
Recursive search (Find anywhere)//book
Select attribute value@id
Transform XML to HTML/TextXSLT
Security (Critical)
Prevent XXE Attacks (#1 Rule)Disable External Entities
Prevent 'Billion Laughs' DoSEntity Expansion Limit
Never trust user-submitted XMLSanitize Inputs
Performance
Load tree in RAM (Manipulation)DOM Parsing
Stream reading (Massive files)SAX / StAX
Binary XML for low bandwidthEXI