Thomas J.S.: XHTML - Wozu <?xml version...> ?

Beitrag lesen

Hallo,

<?xml version="1.0" encoding="iso-8859-1"?>
Sollte man diese Angabe nun verwenden?

Die XML-Deklaration ist optional.
Angeben sollte man es nur, wenn man eine andere Encoding als UTF-8 oder UTF-16 verwendet.

---------------
An XML declaration is not required in all XML documents;
however XHTML document authors are strongly encouraged to use         XML declarations in all their documents.
Such a declaration is required when the character encoding of the document is other than the default UTF-8 or UTF-16 and no encoding was determined by a higher-level protocol.
-----------------

Grüße
Thomas