-1

So far I have

<div itemscope itemtype="http://schema.org/Product"><span itemprop="image" class="fn"><img src="<?php echo $product['thumb']; ?>" alt="<?php echo $product['name']; ?>" /></span></div>

I understand that the fn is supposed to be a value as in <span class="fn">Name</span>, but doesn't an image count as one?

Syntax's: http://schema.org/Product

unor
  • 92,415
  • 26
  • 211
  • 360
Rahul Khosla
  • 349
  • 9
  • 21

2 Answers2

0

Name has the type Text.

That means that the subelement should be a text node, hence you cannot nest other elements, such as an < img ... /> element.

Mads Buch
  • 344
  • 2
  • 10
0

The image property expects a URL as value. You have to use it on an element like img (or a etc.), but not on span.

Note that class names aren’t relevant for Microdata and/or Schema.org. fn appears to be a value of a Microformat (which is something different than Microdata).

unor
  • 92,415
  • 26
  • 211
  • 360