Bug #16033
closed
Login-Page (typo3/index.php): removing whitespace preceding XML Declaration
Added by Toralf Lenz over 18 years ago.
Updated about 6 years ago.
Category:
Backend User Interface
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)
Issue is in the whole BE...
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
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?
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
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?
Confirmed in TYPO3 4.1.7 and 4.2.1
This is related to #19038
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".
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.
This issue has been fixed by Patrick with #20334
The patch has a browser/version check for IE6
Resolved as duplicate of #20334
- Status changed from Resolved to Closed
Also available in: Atom
PDF