Bug #16033
closedLogin-Page (typo3/index.php): removing whitespace preceding XML Declaration
0%
Description
<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
[...]
The HTML-Source isn't correct. (whitespace preceding XML Declaration)
(issue imported from #M3238)
Updated by Ingmar Schlecht over 18 years ago
This is not a problem at all and I just checked that the login page typo3/index.php is indeed valid XHTML.
Do you agree that this bug can be closed?
cheers
Ingmar
Updated by Toralf Lenz over 18 years ago
No!
http://validator.w3.org/ says: "This Page Is Valid XHTML 1.0 Transitional!"
"HTML Tidy for Windows released on 14 February 2006" (http://tidy.sourceforge.net/) says: "removing whitespace preceding XML Declaration"
I think "Tidy" is in the right and the XHTML isn't valid! How does your source text look?
Updated by Ingmar Schlecht over 18 years ago
There is not a single whitespace before "<!DOCTYPE" on my installation.
If there is one on your server, it might be caused by extensions having ext_localconf.php with whitespaces on top.
Anyway, http://validator.w3.org/ is definitely(!) right when it says it's valid XHTML 1.0 Transitional whereas tidy just wants to make it even cleaner than it has to be.
And IMHO having all the doctype and xml declaration on one line without a single whitespace just makes the code harder to read.
cheers
Ingmar
Updated by Toralf Lenz over 18 years ago
The XML Declaration is:
"Whitespace" preceding is:
<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
Valid Source is:
<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
I think BEFORE isn't allowed any character.
or:
The Doctype Declaration must be begin after the XML Declaration and not before. Can anyone confirm this?
Updated by Christian Kuhn over 16 years ago
Confirmed in TYPO3 4.1.7 and 4.2.1
This is related to #19038
Updated by Ingmar Schlecht over 16 years ago
The problem with having the order changed is that IE then switches into quirks mode.
IMHO the issue has zero practical relevancy and therefore should be marked "won't fix".
Updated by Christian Kuhn over 16 years ago
IE7 no longer switches to quirks mode if there is a valid xml declaration preceding the doctype declaration.
So this bug can be fixed as soon as support for IE6 is dropped in the BE.