![]() |
All Good |
What are “Structured data markup”?
<div itemscope itemtype=”http://schema.org/NewsArticle”>
<h2 itemprop=”headline”>Headline/title of the article</h2>
<h3 itemprop=”alternativeHeadline”>If any other headline is there you can use it</h3>
<span itemprop=”description”>Provide a small description </span>
<span itemprop=”articleBody”>The full text/content of the article</span>
<img itemprop=”image1″ src=”image1.jpg” alt=”Image 1 summary”/>
<meta itemprop=”datePublished” content=”2015-02-05T08:00:00+08:00″/>
</div>
For adding alt tag on images, just click on the uploaded image on the post page of blogger and click on properties. You will the option to add it. The above code is published by Google and need a lot of time to add them to your article. Rather than that just use the following code. The code has valid time stamp ISO8601, with Breadcrumb, post-location, and labels. Just search for “post-timestamp'” in blogger template and look for similar codes. Replace or add the existing codes with suitable mark up codes provided here.
<span class=’post-timestamp’>
<b:if cond=’data:post.url’>
<a class=’timestamp-link’ expr:href=’data:post.url’ rel=’bookmark’ title=’permanent link’>
<span itemprop=’datePublished’><abbr class=’published’ expr:title=’data:post.timestampISO8601′><data:post.timestamp/></abbr></span></a> </b:if></span>
<span class=’post-labels’><b:if cond=’data:post.labels’>Hosted in <span typeof=’v:Breadcrumb’>
<b:loop values=’data:post.labels’ var=’label’><a expr:href=’data:label.url’ itemprop=’url’ property=’v:title’ rel=’v:url’> <data:label.name/></a>
<b:if cond=’data:label.isLast != "true"’>, </b:if></b:loop></span><b:if cond=’data:post.url’><span class=’post-location’> </span></b:if> </b:if> </span>
If you do not have a breacrum, you can add it to your site through “add breadcrumb navigation“. The date published in ISO format and that is,
Date: 2015-04-19
Combined date and time in UTC: 2015-04-19T12:59:23+00:00
2015-04-19T12:59:23Z
Week: 2015-W16
Date with week number: 2015-W16-7
Ordinal date: 2015-109
For search box use the following code,
<div itemscope itemtype=”http://schema.org/WebSite”>
<meta itemprop=”url” content=”https://www.example.com/”/>
<form itemprop=”potentialAction” itemscope itemtype=”http://schema.org/SearchAction”>
<meta itemprop=”target” content=”https://query.example.com/search?q={search_term_string}”/>
<input itemprop=”query-input” type=”text” name=”search_term_string” required/>
<input type=”submit”/>
</form>
</div>
For showing your site name in the search results, use the following code,
<head itemscope itemtype=”http://schema.org/WebSite”>
<title itemprop=’name’><data:blog.pageTitle/></title>
<link rel=”canonical” href=”https://example.com/” itemprop=”url”>
What is the use of “Structured data markup”?
How will I analyse snippets using the “Structured data markup Testing Tool” From Webmasters?
Go to Google webmaster > Other resources > Structured markup testing tool
or just go directly to the Structured markup testing tool > Put your desired link there in the box > “Fetch and Validate”
Structured Data Markup Rich Snippets for Recipes
<script type=”application/ld+json”>
{
“@context”: “http://schema.org/”,
“@type”: “Recipe”,
“name”: “Perfect Apple Pie”,
“author”: “Gin Blanco”,
“image”: “http://images.edge-generalmills.com/56459281-6fe6-4d9d-984f-385c9488d824.jpg”,
“description”: “A classic apple pie takes a shortcut with easy Pillsbury® unroll-fill refrigerated pie crust.”,
“aggregateRating”: {
“@type”: “AggregateRating”,
“ratingValue”: “4.5”,
“reviewCount”: “276”,
“bestRating”: “5”,
“worstRating”: “1”
},
“prepTime”: “PT30M”,
“totalTime”: “PT3H”,
“recipeYield”: “8”,
“nutrition”: {
“@type”: “NutritionInformation”,
“servingSize”: “1 medium slice”,
“calories”: “230 calories”,
“fatContent”: “1 g”,
“carbohydrateContent”: “43 g”,
“cholesterolContent”: “0 mg”,
“fiberContent”: “1 g”,
“proteinContent”: “1 g”,
“saturatedFatContent”: “2 ½ g”,
“servingSize”: “1 Serving”,
“sodiumContent”: “200 mg”,
“sugarContent”: “27 g”,
“transFatContent”: “0 g”
},
“recipeIngredient”: [
“1 box Pillsbury™ refrigerated pie crusts, softened as directed on box”,
“6 cups thinly sliced, peeled apples (6 medium)”,
“3/4 cup sugar”,
“2 tablespoons all-purpose flour”,
“3/4 teaspoon ground cinnamon”,
“1/4 teaspoon salt”,
“1/8 teaspoon ground nutmeg”,
“1 tablespoon lemon juice”
],
“recipeInstructions”: [
“1 Heat oven to 425°F. Place 1 pie crust in ungreased 9-inch glass pie plate. Press firmly against side and bottom.”,
“2 In large bowl, gently mix filling ingredients; spoon into crust-lined pie plate. Top with second crust. Wrap excess top crust under bottom crust edge, pressing edges together to seal; flute. Cut slits or shapes in several places in top crust.”,
“3 Bake 40 to 45 minutes or until apples are tender and crust is golden brown. Cover edge of crust with 2- to 3-inch wide strips of foil after first 15 to 20 minutes of baking to prevent excessive browning. Cool on cooling rack at least 2 hours before serving.”
]
}
</script>
Structured Data Markup Rich Snippets for Events
<script type=”application/ld+json”>
{
“@context”: “http://schema.org”,
“@type”: “Event”,
“name”: “Example Band goes to San Francisco”,
“startDate” : “2013-09-14T21:30”,
“url” : “http://example.com/tourdates.html”,
“location” : {
“@type” : “Place”,
“sameAs” : “http://www.hi-dive.com”,
“name” : “The Hi-Dive”,
“address” : “7 S. Broadway, Denver, CO 80209”
}
}
</script>
Structured Data Markup Rich Snippets for Products
<script type=”application/ld+json”>
{
“@context”: “http://schema.org/”,
“@type”: “Product”,
“name”: “Executive Anvil”,
“image”: “http://www.example.com/anvil_executive.jpg”,
“description”: “Sleeker than ACME’s Classic Anvil, the Executive Anvil is perfect for the business traveler looking for something to drop from a height.”,
“mpn”: “925872”,
“brand”: {
“@type”: “Thing”,
“name”: “ACME”
},
“aggregateRating”: {
“@type”: “AggregateRating”,
“ratingValue”: “4.4”,
“reviewCount”: “89”
},
“offers”: {
“@type”: “Offer”,
“priceCurrency”: “USD”,
“price”: “119.99”,
“priceValidUntil”: “2020-11-05”,
“itemCondition”: “http://schema.org/UsedCondition”,
“availability”: “http://schema.org/InStock”,
“seller”: {
“@type”: “Organization”,
“name”: “Executive Objects”
}
}
}
</script>
Structured Data Markup Rich Snippets for Reviews
<script type=”application/ld+json”>
{
“@context”: “http://schema.org/”,
“@type”: “Review”,
“itemReviewed”: {
“@type”: “Thing”,
“name”: “Super Book”
},
“author”: {
“@type”: “Person”,
“name”: “Joe”
},
“reviewRating”: {
“@type”: “Rating”,
“ratingValue”: “7”,
“bestRating”: “10”
},
“publisher”: {
“@type”: “Organization”,
“name”: “Washington Times”
}
}
</script>
Kindly share this post