How to Hide Tracking Pixel

I have a tracking pixel that is unfortunately causing a small white bar at the bottom of my footer. What is the best way to hide the pixel?

I was thinking of putting it (and my other pixels) in a position: absolute div, which hides the bar properly but I'm not sure if that will prevent the pixel from working on some browsers.


From google Support:

<img src="TRACKING-PIXEL-URL-GOES-HERE" style="position:absolute; visibility:hidden">

<img src="TRACKING-PIXEL-URL-GOES-HERE" style="display:none">

<img src="TRACKING-PIXEL-URL-GOES-HERE" width="0" height="0">

You could give it a display: none CSS declaration or alternatively you could give the footer a negative bottom margin value margin-bottom: -1px

My tracking pixels were getting added automatically via javascript but all of them had a width and height of 1 defined <img src="" width="1" height="1" /> so I hid them by targeting those attributes:

img[width="1"][height="1"] {
  display: none;

You could alternatively target the src:

img[src=""] {
  display: none;

You can also mask out in CSS a larger range of 1 pixel links, including data blob based images, like this:

*[src*='data:image'] {
    display: none;

Need Your Help

undefined reference to template function

c++ qt boost undefined-reference

I have three files . The contents of main.cpp are