Search…

X3 Photo Gallery Support Forums

Search…
 
metallissimus
Experienced
Topic Author
Posts: 331
Joined: 17 Oct 2019, 06:54

Google can't read stylesheet

13 Sep 2022, 10:43

I am having trouble getting one of my pages indexed and on investigating the issue I found the following (which might or might not be a cause for the problem):

When I check the URL (https://hochzeiten.danielbollinger.de/h ... den-baden/) in Google Search Console via Live Test it tells me the page is not usable on mobile devices. I know that's wrong, but to Google it seems to be correct, because what they see is this (screenshot from the GSC):
Bildschirmfoto 2022-09-13 um 16.38.49.png
Bildschirmfoto 2022-09-13 um 16.38.49.png (283.25 KiB) Viewed 1735 times
It looked to me like no styling applied and actually that seems to be exactly the case.
Bildschirmfoto 2022-09-13 um 16.39.47.png
Bildschirmfoto 2022-09-13 um 16.39.47.png (64 KiB) Viewed 1735 times
Translation:
"Page ressources
12/23 could not be loaded

Googlebot blocked by robots.txt"

Anything I can do about that?
www.danielbollinger.de – corporate photography
hochzeiten.danielbollinger.de – wedding photography
 
User avatar
mjau-mjau
X3 Wizard
Posts: 13993
Joined: 30 Sep 2006, 03:37

Re: Google can't read stylesheet

13 Sep 2022, 11:45

metallissimus wrote:"Page ressources
12/23 could not be loaded

Googlebot blocked by robots.txt"
This is your robots.txt:
https://hochzeiten.danielbollinger.de/robots.txt
Code
# www.robotstxt.org

User-agent: *
Allow: /
Disallow: /app/
Disallow: /panel/
Disallow: /content*/$
Remove the line:
Code
Disallow: /app/
Or use the CDN version? There is no specific law about blocking access to resources that you don't want Google to index. For example, it's perfectly legitimate to block access to images on a page, yet still require the page to get indexed. It could be that Google wants to see what your page looks like though with CSS applied ... It is not affecting your other pages indexed by Google, but perhaps you changed to non-CDN assets recently.
 
metallissimus
Experienced
Topic Author
Posts: 331
Joined: 17 Oct 2019, 06:54

Re: Google can't read stylesheet

13 Sep 2022, 12:26

mjau-mjau wrote: but perhaps you changed to non-CDN assets recently.
I did, already a while ago, because of the whole GDPR thing. It's about the same as with Google fonts... you can't  relay a visitor's IP without their consent.

So I will change the robots.txt, thanks. I was afraid of security issues, but I guess you wouldn't have suggested this if there were.

Edit: Somehow Google now could read the stylesheet but just doesn't (no reason given). So I will turn back on the CDN and deal with the legal side of it...
www.danielbollinger.de – corporate photography
hochzeiten.danielbollinger.de – wedding photography
 
User avatar
mjau-mjau
X3 Wizard
Posts: 13993
Joined: 30 Sep 2006, 03:37

Re: Google can't read stylesheet

13 Sep 2022, 12:59

metallissimus wrote:So I will change the robots.txt, thanks. I was afraid of security issues, but I guess you wouldn't have suggested this if there were.
There are no security related issues with robots.txt. It simply tells Google what to NOT index, even if it knows the files are there.
metallissimus wrote:I did, already a while ago, because of the whole GDPR thing. It's about the same as with Google fonts... you can't  relay a visitor's IP without their consent.
It doesn't state anywhere that "you can't relay a visitor's IP without their consent". The base of this single ruling in history, in Germany, in Munich court only, is that the fonts "could" have be hosted locally, without affecting the usability of the website in any way. CDN services affect the quality, speed and function of a website, and not only the aesthetic value in the form of fonts, as is the case with Google Fonts. Read about it:
https://www.jsdelivr.com/blog/how-the-g ... fe-to-use/
 
metallissimus
Experienced
Topic Author
Posts: 331
Joined: 17 Oct 2019, 06:54

Re: Google can't read stylesheet

13 Sep 2022, 14:14

mjau-mjau wrote: It doesn't state anywhere that "you can't relay a visitor's IP without their consent".
That was kind of the essence I remember from the article that made me turn off CDN back then. But that article wasn't specificially about jsDelivr rather about CDNs and GDPR in general. So thanks a lot for the link, the text really covers the topic quite extensively and convincingly.
www.danielbollinger.de – corporate photography
hochzeiten.danielbollinger.de – wedding photography