Skip to content
Grav 2.0 is officially stable. Read the announcement →
Archive

Inherited theme causes empty first line in all documents

Started by Muut Archive 9 years ago · 5 replies · 391 views
9 years ago

I am using a theme inherited from Antimatter. Once this theme is activated all generated pages start with an empty line. (I added line numbers to code below for better explanation)

TXT
1 
2 <!DOCTYPE html>
3 <html lang="de">
4 <head>
5 ...

This behavior is annoying in combination with sitemap plugin as it leads to a faulty XML document.

If i switch to plain Antimatter the empty line is gone.
Any idea how I can get rid of this empty line in my inherited theme?

9 years ago

I am unable to replicate this problem. Please post a zip of your child theme to test.

9 years ago

I did some further testing and have created a simplified version of the website, i.e. child theme reduced to essentials, web pages just copied from antimatter example, most of the plugins deinstalled. Updates of today installed. Issue is still there. I have posted a zip of the simplified web site under the same link than the full child theme.

9 years ago

I opened your theme's main php file and just saved, and it was fixed. The issue is you have some white space after the closing ?> tag.

I have my editor configured to strip white space, you might want to do the same.

9 years ago

Thank you very much for your great support. You helped me a lot. Issue is fixed. You made my day.

Suggested topics

Topic Participants Replies Views Activity
Archive · by Deleted User, 9 years ago
0 1344 9 years ago
Archive · by Muut Archive, 9 years ago
2 930 9 years ago
Archive · by Muut Archive, 9 years ago
2 4058 9 years ago
Archive · by Muut Archive, 9 years ago
1 2943 9 years ago
Archive · by Muut Archive, 9 years ago
3 1116 9 years ago