There are two rules for attributes in XML documents:
Attributes must have values
Those values must be enclosed within quotation marks
Compare the two examples below. The markup at the top is legal in HTML, but not in XML. To do the equivalent in XML, you have to give the attribute a value, and you have to enclose it in quotes.
<!-- NOT legal XML markup -->
<ol compact>
<!-- legal XML markup -->
<ol compact="yes">
You can use either single or double quotes, just as long as you're consistent.
If the value of the attribute contains a single or double quote, you can use the other kind of quote to surround the value (as in name="Doug's car"), or use the entities " for a double quote and ' for a single quote. An entity is a symbol, such as ", that the XML parser replaces with other text, such as ".