Welcome to WebmasterWorld Guest from 3.81.29.226

Forum Moderators: not2easy

Message Too Old, No Replies

Does Google read external style sheets

     
10:06 am on Jun 10, 2008 (gmt 0)

Junior Member

10+ Year Member

joined:Feb 17, 2003
posts: 76
votes: 0


Hello all,

I am sure that this question has been asked many times before but I am unable to find an up to date answer to this question...

Is Google yet capable of reading external style sheet files?

Checking my logs and there is no recorded access of my stylesheet file being accessed by the Google Bot.

However I wish to use the display:none property in an external stylesheet to hide content depending on a users choice/preference. I don't wish to do this to increase my search engine rankings and this hidden text won't be stuffed with keywords - its just to make my pages simpler for me when coding. But at the same time I don't want the site to be penalised either.

Can you let me have your thoughts on this if possible please?

Thanks

Caz

10:27 am on June 10, 2008 (gmt 0)

Senior Member

WebmasterWorld Senior Member suzyuk is a WebmasterWorld Top Contributor of All Time 10+ Year Member

joined:Oct 1, 2002
posts:5199
votes: 0


There have been reports of Googlebot fetching some stylesheets, I myself have never seen it

I *think* as part of Google Algo that they may very well try to fetch a stylesheet for further reading *if* the site it's crawling also raises some other flags.

I do not believe it can or ever will simply fetch a stylesheet and parse it for the words

display: none;
or
visibility: hidden;
or
z-index: -9999px;
etc..

the Cascade and Specificty would make it very hard for them to put it all in context based on a single rule and besides there are very many legitimate uses for such rules. If anything they, Google, might just get enough flags from various sources of their algo, not just the CSS, to warrant a hand check on a site. So if you're using it legitimately all will be well, regardless of if the stylesheet is read or not.

There's a lot of FUD promoted about stylesheet properties and hidden text, but common sense always prevails ;)
Google themselves are using an image replacement technique which uses the word "hidden" in the CSS

hth

10:27 am on June 10, 2008 (gmt 0)

Senior Member

WebmasterWorld Senior Member swa66 is a WebmasterWorld Top Contributor of All Time 10+ Year Member

joined:Aug 7, 2003
posts:4783
votes: 0


I've seen GoogleBot downloading an external CSS file on one of my sites.
Obviously I've no idea what they do with them.

I think the official Google point of view is "do not cheat". So focus on your visitors and give them the best experience.

An example of today (Italics are obfuscated to anonymize it all):

[i]Goolge owned IP[/i] - - [10/Jun/2008:[i]time[/i] +0200] "GET [i]file.css[/i] HTTP/1.1" 200 [i]size[/i] "-" "Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)"

I've never seen GoogleBot download a CSS file mentioned in a conditional comment, but the others on that site: they all get touched every once in a while.

8:59 pm on June 10, 2008 (gmt 0)

Senior Member

WebmasterWorld Senior Member penders is a WebmasterWorld Top Contributor of All Time 10+ Year Member Top Contributors Of The Month

joined:July 3, 2006
posts: 3153
votes: 7


I wish to use the display:none property in an external stylesheet to hide content depending on a users choice/preference.

This is a common technique to make a page dynamic and more usable. For Google to penalise a page let alone an entire site for this technique would be very wrong IMO. I would have thought/hoped that Google would at worst simply ignore such (hidden) content? (Which by the sound of it is OK by you?) If Google was to penalise sites for simply toggling content the web would not be a better place. As SuzyUK says... common sense I reckon.

9:15 pm on June 10, 2008 (gmt 0)

Senior Member

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month

joined:Feb 12, 2006
posts:2710
votes: 116


the old trick of writing a load of keywords in the same color as the background color stopped working a long time ago. presumably the only way they'd know you're doing it is to compare the colors in the stylesheet.

i can't believe they'd only ever check that manually

10:10 pm on June 10, 2008 (gmt 0)

Senior Member

WebmasterWorld Senior Member suzyuk is a WebmasterWorld Top Contributor of All Time 10+ Year Member

joined:Oct 1, 2002
posts:5199
votes: 0


i can't believe they'd only ever check that manually

really? I can't believe some would be asking the question of a CSS (that'll be a text file) file? maybe we should check the google forums, or better yet let's check Matt Cutt's blog for what we're (CSS'er's) allowed to do :o ..

6:30 am on June 11, 2008 (gmt 0)

Senior Member

WebmasterWorld Senior Member swa66 is a WebmasterWorld Top Contributor of All Time 10+ Year Member

joined:Aug 7, 2003
posts:4783
votes: 0


Since the code of multiple rendering engines used in browsers is out there, I don't see why Google could not render it virtually and check in the process if they see trickery they don't like. They do own a few machines ...
1:16 pm on June 12, 2008 (gmt 0)

Junior Member

10+ Year Member

joined:Feb 17, 2003
posts:76
votes: 0


Thanks to you all for your input!

Based on this fact:

Google themselves are using an image replacement technique which uses the word "hidden" in the CSS

I think I will go ahead and offer my visitors on page customisation whilst keeping coding to a minimum for me!

Thanks again...

Caz

7:42 pm on June 12, 2008 (gmt 0)

Senior Member

WebmasterWorld Senior Member suzyuk is a WebmasterWorld Top Contributor of All Time 10+ Year Member

joined:Oct 1, 2002
posts:5199
votes: 0


you're welcome Caz.

thanks for asking, & do come back out of lurkdom again soon!

9:14 pm on June 12, 2008 (gmt 0)

Senior Member

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month

joined:Aug 29, 2006
posts:1378
votes: 18


There have been reports of Googlebot fetching some stylesheets

I have CSS, JavaScript and images blocked in robots.txt and GoogleBot never takes them.

But the GooglePlex does.

Every so often a single CSS file, or perhaps a JavaScript file, or a few images, is fetched from my site by a client using a Google IP, often masquerading as a Firefox browser, as part of an apparently automated quality control procedure.

The CSS and JavaScript files do not exist in isolation - they require context to be meaningful - and I assume Google matches them with particular HTML pages. But the various files are not fetched together as they would be by a human viewer.

Google doing quality control is no surprise, though, and is fine by me.

...

1:49 pm on June 17, 2008 (gmt 0)

Junior Member

10+ Year Member

joined:Feb 17, 2003
posts:76
votes: 0


do come back out of lurkdom again soon!

That did make me chuckle!

Thanks for the input Samizdata - most helpful. - This will be fine by me also.

9:43 pm on June 25, 2008 (gmt 0)

Senior Member

WebmasterWorld Senior Member suzyuk is a WebmasterWorld Top Contributor of All Time 10+ Year Member

joined:Oct 1, 2002
posts:5199
votes: 0


Glad you had a chuckle, we've got to do that!

But the GooglePlex does.

exactly!

that's always been the case.. but still it it is not the same same as "knowing" what is right or wrong, is it?