Archived topic
White bar at top of site
3 replies · Started by David on February 17, 2022
Hi
I am seeing a white gap at the top of my site for all pages. Can't seem to figure out what is causing this at all!
I have checked pretty much everything I can think of including padding etc. as found here https://generatepress.com/forums/topic/remove-white-space-on-top-of-page/
Could someone please let me know what they think the issue is?
Hi David,
Do you have any custom PHP snippets added to the site?
There seems to be an HTML syntax issue w/ the site as some elements that should normally appear within the <head> appears inside the <body> as shown here - https://share.getcloudapp.com/DOum7KB6
Can you try disabling these snippets (if any) and see if it addresses the issue?
Hi Elvin
Thanks for looking at this.
I'm struggling to find where this would be to solve it. We use php snippets plugin but i have disabled this and it still persists. Could it be something added to functions.php?
Hi there,
looking at the issue that Elvin pointed out.
The last element in the <head> is this:
<script src="//ajax.googleapis.com/ajax/libs/webfont/1.5.18/webfont.js" async=""></script>
And the first element in the body is:
<svg width="0" height="0" class="h5ap_svg_hidden">
So the chances are the issue is either related to a) the code adding the webfont.js or b) the code adding that SVG which is the first of two SVG symbols.
Maybe they give some clues to what is breaking the code.