Pergunta

In HTML, you can have empty attributes, without even ="":

<input type="checkbox" selected></input>

However, in XHTML, you need at least an empty string:

<input type="checkbox" selected="selected"></input>

What is the equivalent of the empty HTML attribute in XHTML? Is it an empty string, or the attribute name as a string, or true, or something else?

Foi útil?

Solução

http://www.w3.org/TR/2000/REC-xhtml1-20000126/#h-4.5

Equivalent of the empty HTML attribute in XHTML is attribute name.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top