According to some SEO experts and theories like Progressive Enhancement (PE), page content should be presented appropriately to users even with JS disabled. And I totally agree with this.
Here is my situation, on our client's About Us page, there is a div which lists their company events. Due to space and another considerations they hide some of event lists with JS as well as CSS element display:none
.
So far, two things really really scare me about this.
display:none
. My experience tells this is very dreadful in terms of SEO.In addition to those two scaring things, I also have one puzzlement.
I used Google web master tool to fetched this page and it showed all of hide event lists. If Google robot craws my site with JS disabled, how could it fetch those hidden content? or if it is able to fetch those hidden content, does it mean the PE theory is outdated and those experts are wrong?
What should I do now? Thank you for your time.
Firstly, display:none
is not universally considered to be a SEO faux pas; crawlers can still 'crawl' that text; there are just conflicting theories as to if it affects reputation, or if they'll index it with equal weight.
The PE theory and SEO/findability theory overlap, but their 'interests' differ at times; you could in theory do something thats bad PE without it being bad SEO.
If JavaScript is disabled, PE theory says 'you should be able to functionally use all of the site'. But, if the default is display:none;
and it becomes display: block;
via JavaScript, that's not PE, since a JS disabler could never view your content (though a crawler might).
The better practice is to have display:(not none
) be the default, and set display: none; via JavaScript. That way, JS disablers see and use the content (even if in a visually unappealing way), and enablers experience it the way you inteded
That covers you on both counts, since crawlers can't tell if JS is being used to hide something, in case there IS SEO-negativity associated with display:none;
Spiders essentially see what you see when you "view source." If you hide your content with CSS or JS, chances are the spider will still be able to see them because they mostly look at the raw HTML source (where the content was declared). However, if you load your content with JS (via AJAX, etc.) then spiders will not be able to see your content because they do not typically execute javascript.
As long as all content is described in the HTML source then you should be OK for the most part.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With