Mobile app version of vmapp.org
Login or Join
Fox8124981

: Should I be concerned for SEO when hiding images? I'm using fancybox 2 with the following code (demo here): <a class="fancybox" href="http://a.com/bmw-328-manual-2008-black-18-inch-rims.jpg" title"bmw

@Fox8124981

Posted in: #Bing #Google #SearchEngines #Seo

I'm using fancybox 2 with the following code (demo here):

<a class="fancybox"
href="http://a.com/bmw-328-manual-2008-black-18-inch-rims.jpg"
title"bmw 328 manual 2008 black 18 inch rims">
<img alt="bmw 328 manual 2008 black 18 inch rims"
src="http://a.com/bmw-328-manual-2008-black-18-inch-rims-s.jpg" />
</a>

<div class="hidden">
<a class="fancybox"
href="http://a.com/bmw-328-manual-2008-black-18-inch-rims.jpg"
title"bmw 328 manual 2008 black 18 inch rims">
<img alt="bmw 328 manual 2008 black 18 inch rims"
src="http://a.com/bmw-328-manual-2008-black-18-inch-rims-s.jpg" />
</a>

<a class="fancybox"
href="http://a.com/bmw-328-manual-2008-black-18-inch-rims.jpg"
title"bmw 328 manual 2008 black 18 inch rims">
<img alt="bmw 328 manual 2008 black 18 inch rims"
src="http://a.com/bmw-328-manual-2008-black-18-inch-rims-s.jpg" />
</a>
</div>


As you can see, the first image is visible, the 2 others are only visible when the first one is clicked on, this triggers fancybox to start:

$(".fancybox")
.attr('rel', 'gallery')
.fancybox({
padding : 0
});


With the CSS:

.hidden {
display: none;


}

A question here addresses something that concerns me. The main difference is that I use words in the file name, alt tag and title tag to describe the item.

The title is displayed by fancybox when triggered.

I wonder if this would look like spam to search engines, would it?

10.02% popularity Vote Up Vote Down


Login to follow query

More posts by @Fox8124981

2 Comments

Sorted by latest first Latest Oldest Best

 

@Speyer207

Google reads content within a element that uses display:none, it also checks to make sure there is a trigger point, i.e that the content can be revealed though JavaScript.

Many people don't put in trust in Google being able to understand their scripts and many people opt to use <noscript> as Anthony has mentioned, using noscript ensures that Google doesn't can reveal the data without the need of a trigger. Content that has no triggers can be punished by Google since so many people have hidden content for manipulation of search results. By using <noscript> its a win win situation since Google will 100% see the content with no problems and also has the benefit of users that disabled JavaScript can view the page.

While its a minor issue using rel=" " will fail validation as it was never designed to act as a hook, you should opt to use data-fancybox-group=" " Which I believe is included in fancybox v2 and above.

Furthermore

As far as us SEO'ers are lend to believe Google currently does not take the title tag into account. Personally I'd not use the title tag at all and have a caption as well as a ALT tag, these should be different from one another. This way your provide text content to go with your images which should in turn give better SEO content wise as well as giving Google more signals to rank the image on their image search platform.

Treat ALT tag as a short description, and a caption with more in-depth information in regards of the image, Google is good at grouping the elements to tie them together which will improve SEO. Believe is a example of the code:

<div class="myfancybox">
<a class="fancybox" href="cat-being-sick.jpg">
<img src="cat-being-sick-small.jpg" alt="a Cat being sick" />
<div class="caption">Feeding your cat rice will make your cat sick</div>
</a>
</div>

10% popularity Vote Up Vote Down


 

@Goswami781

No you shouldn't concern yourself, it makes perfect user sense.

If you want to be nice to those with javascript disabled though you could place a <noscript> element with your hidden images.

I would also put the photo numbers in the alt tags, something like alt="Photo #2 of bmw 328 manual 2008 black 18 inch rims"

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme