In HTML5 there are tags that must have a starting and an ending tag even when their content is empty:
<script></script> <!-- Right way. -->
<div></div> <!-- Right way. -->
<content></content> <!-- Right way. -->
<script/> <!-- Wrong way. -->
<div/> <!-- Wrong way. -->
<content/> <!-- Wrong way. -->
In XML this difference doesn't exist:
<node/>
and <node></node>
are the same entity.
Why tags like script
, div
and content
can't be defined simply as:
<script/>
, <div/>
and <content/>
?