Archived topic
Generatepress page hero logo 2x issue
3 replies · Started by Daniel on June 10, 2021
Dear all,
I am using generatepress 3.0.3 and GP Premium 2.0.0-rc.2. I am using header elements on various pages of my site. These header elements have a custom site logo.
Pages without the header element have the normal logo like this:
<div class="site-logo">
<a href="#" title="title" rel="home">
<img class="header-image is-logo-image" alt="title" src="https://...normal_header.png" title="title" width="2000" height="300" />
</a>
</div>
The pages with custom header element and with custom logo have this additional code:
<div class="site-logo page-hero-logo">
<a href="#" title="title" rel="home">
<img class="header-image is-logo-image" alt="title" src="https://...custom_header.png" title="title" srcset="...custom_header.png 1x, 2x" width="2000" height="300" />
</a>
</div>
The 'problem' comes with the 2x in srcset. My company runs a linkchecker https://github.com/linkchecker/linkchecker and the linkchecker gives an alarm:
# sec
- Result Error: 404 Not Found...
- Parent URL: https://www.url.de/
- Real URL: https://www.url.de/2x
Is this a real issue or is the linkchecker at fault? Regards
Hi there,
Line checker isn't wrong here... but browsers ignore the absence of the URL for 2x image and just use the x1 element in its absence.
Great, thank you for clarification!
You're welcome