1

Blog is not a known valid target type for the mainContentOfPage property.

I have tried many optins to set mainContentOfPage property on http://www.thecreativedev.com

I have

<div itemprop="mainContentOfPage" itemscope="itemscope" itemtype="http://schema.org/Blog"> --> This is outside the loop

<div itemscope="itemscope" itemtype="http://schema.org/BlogPosting" itemprop="blogPost"> --> This is in loop

But no solution worked. I tried solution provided on Best way to markup "mainContentOfPage"?

Anyone can help me in this?

Community
  • 1
  • 1
Bhumi Shah
  • 9,323
  • 7
  • 63
  • 104
  • Do you have a `WebPage` (or similar) item around the `div` with the `mainContentOfPage` property? -- Is this example snippet from the blog’s homepage? And for a page about a single blog post you use different markup? – unor Oct 02 '15 at 07:06
  • This is the snippet set on blog homepage. – Bhumi Shah Oct 02 '15 at 09:08
  • I updated my answer with an example. – unor Oct 02 '15 at 14:45

1 Answers1

4

I suspect that you don’t want to use the mainContentOfPage property. It’s not really useful for the average webpage, because it expects a WebPageElement as value (which represents things like the navigation, the footer or the sidebar), not what is actually the main content of a page (like a blog post).

If you want to denote that the Blog is the primary thing the WebPage is about (e.g., on the blog’s homepage), you might want to use the mainEntity property (and for the other direction, the inverse property mainEntityOfPage).

It could look like this (using Microdata):

<body itemscope itemtype="http://schema.org/WebPage">
  <section itemprop="mainEntity" itemscope itemtype="http://schema.org/Blog">
    <article itemprop="blogPost" itemscope itemtype="http://schema.org/BlogPosting"></article>
    <article itemprop="blogPost" itemscope itemtype="http://schema.org/BlogPosting"></article>
    <article itemprop="blogPost" itemscope itemtype="http://schema.org/BlogPosting"></article>
  </section>
</body>
unor
  • 92,415
  • 26
  • 211
  • 360
  • you mean maincontentofPage is not required as this is blog site? and can replace mainentitypage? – Bhumi Shah Sep 30 '15 at 17:24
  • @BhumiShah: Schema.org never requires that certain properties have to be used, but you might have of course other parties that "require" something like that. Anyway, to decide if you can simply replace the property, you would have to include a minimal (!) example of your markup in your question. – unor Sep 30 '15 at 17:29
  • unor: I am not getting you.I don't have much knowledge about rich content so, – Bhumi Shah Sep 30 '15 at 17:41
  • What I mean is, if you want a more specific answer, you should edit your question to include a short markup example (= show us the relevant parts of your Microdata with how you use `mainContentOfPage` currently). – unor Sep 30 '15 at 18:43
  • You can check my domain url on google tool. They are showing error. – Bhumi Shah Sep 30 '15 at 18:45
  • 1
    @BhumiShah: I know, but it’s important that you include a minimal example in your question -- otherwise, if you change something on your live page (or if you delete your site, etc.), this question is not useful to anyone in the future. – unor Sep 30 '15 at 18:46
  • 1
    Okay. Thanks for your suggestion. Will improve question – Bhumi Shah Sep 30 '15 at 18:47
  • unor: You are awesome.Thanks. – Bhumi Shah Oct 03 '15 at 17:21