-
I noticed some lines of whitespace before the doctype. My first assumption was that I accidentally had left whitespace in functions.php or in some other include, or that it was introduced by some plugin.
So I switched to the parent theme, and disabled ALL plugins… but the problem persisted. See image.
I’m not sure what causes it. A stray utf-8 BOM? Some linebreak oddity? Forgotten whitespace after a ?> ? It is easy to get stray whiteline when going in and out of PHP as much as you do.
I chose about 10 files at random from the parent theme, copied the code, pasted in new documents, and saved over the original files with the same names.
Then I checked again – and one troublesome line had vanished. Only one empty line before Doctype now.Can you check your files for utf-8 BOMs and stray whitespace?
Whitespace before doctype
This topic is: resolved