Schema
HTML
<!-- Schema -->
<script type="application/ld+json">{
"@context": "http://schema.org",
"@type": "LocalBusiness",
"address": {
"@type": "PostalAddress",
"addressLocality": "Mississauga",
"addressRegion": "ON",
"postalCode": "L5N 5M1",
"streetAddress": "25- 6800 Kitimat Road"
},
"description": "We are Attic Insulation Experts, offering a wide range of Attic & Roof services. We create efficient, healthy, and worry-free attics!We make your home more efficient and lower your energy costs. Proper Attic insulation saves you money and ensures a more comfortable home year-round. We only use the SAFEST, Chemical-Free, Canadian Approved materials. All our work is Warranted, Guaranteed and Insured.",
"name": "EcoComfort Insulation & Consulting Inc.",
"telephone": "1-416-333-4554",
"openingHours": "Mo,Tu,We,Th,Fr 08:00-17:00",
"url": "https://www.ecocomfortinsulators.ca/",
"logo": "https://www.ecocomfortinsulators.ca/img/logo.png",
"image": "https://www.ecocomfortinsulators.ca/img/welcome.jpg",
"email": "info@ecocomfortinsulators.ca",
"sameAs": [
"https://www.youtube.com/channel/UCBYALLDj8_dy6fgtaUKeCUQ",
"https://www.facebook.com/amwindowanddoor/"
],
"hasMap": [
"https://www.google.com/maps?ll=43.606885,-79.735514&z=14&t=m&hl=en-US&gl=CA&mapclient=embed&cid=996220263715687767"
],
"geo": {
"@type": "GeoCoordinates",
"latitude": "43.606885",
"longitude": "-79.735514"
}
} </script>
Schema search
HTML
<!-- Schema search-->
<script type="application/ld+json">
{
"@context": "http://schema.org",
"@type": "WebSite",
"url": "http://am.xidigital.pp.ua/",
"potentialAction": {
"@type": "SearchAction",
"target": "http://am.xidigital.pp.ua//search?search_product={search_term_string}",
"query-input": "required name=search_term_string"
}
}
</script>
Schema FAQs
PHP
<!-- Schema FAQs-->
<h1>FAQS</h1>
<ol>
<?php $counter=1;
foreach($faqs as $item):?>
<li class="faqs_item || <?=($counter==1 ? 'active' : '')?>">
<div class="faqs_question"><?=$item['name']?></div>
<div class="faqs_content || content" <?=($counter==1 ? 'style="display: block;" ' : '')?>>
<?=$item['value']?>
</div>
</li>
<?php $counter++;
endforeach;?>
</ol>
<?php $faq_count = count($faqs);?>
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "FAQPage",
"mainEntity": [
<?php $counter=1;
foreach($faqs as $item):?>
{
"@type": "Question",
"name": "<?= htmlspecialchars($item['name'], ENT_QUOTES) ?>",
"acceptedAnswer": {
"@type": "Answer",
"text": "<?= htmlspecialchars(strip_tags($item['value']), ENT_QUOTES)?>"
}
}<?=($counter < $faq_count ? ',' : '')?>
<?php $counter++;?>
<?php endforeach;?>
]
}
</script>
Schema Article
PHP
<!-- Schema Article-->
<script type="application/ld+json">
{
"@context": "https://schema.org/",
"@type": "Article",
"name": "<?=htmlspecialchars($page['name'],ENT_QUOTES)?>",
"headline": "<?=htmlspecialchars($page['name'],ENT_QUOTES)?>",
"mainEntityOfPage": {
"@type": "WebPage",
"@id": "https://<?=$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI']?>"
},
"author": "Shulman",
"publisher": {
"@type": "Organization",
"name": "ShulmanWeightloss",
"logo": {
"@type": "ImageObject",
"url": "https://www.shulmanweightloss.com/img/logo_og.jpg"
}
},
"image": "<?=isset($OG_IMAGE) ? 'https://www.shulmanweightloss.com'.$OG_IMAGE : 'https://www.shulmanweightloss.com/img/logo_og.jpg'>?",
"datePublished": "<?=date('Y-m-d',strtotime($page['date']))?>",
"dateModified": "<?=date('Y-m-d',strtotime($page['date']))?>"
}
</script>
Breadcrumbs Schema
HTML
<nav aria-label="Breadcrumb" class="breadcrumbs_nav">
<ol class="breadcrumbs" itemscope itemtype="https://schema.org/BreadcrumbList">
<li itemprop="itemListElement" itemscope itemtype="https://schema.org/ListItem">
<a itemprop="item" href="https://example.com">
<span itemprop="name">Home</span>
</a>
<meta itemprop="position" content="1" />
</li>
<li itemprop="itemListElement" itemscope itemtype="https://schema.org/ListItem">
<a itemscope itemtype="https://schema.org/WebPage" itemprop="item" itemid="https://example.com/books" href="https://example.com/books">
<span itemprop="name">Books</span>
</a>
<meta itemprop="position" content="2" />
</li>
<li itemprop="itemListElement" itemscope itemtype="https://schema.org/ListItem">
<a itemscope itemtype="https://schema.org/WebPage" itemprop="item" itemid="https://example.com/books/sciencefiction" href="https://example.com/books/sciencefiction">
<span itemprop="name">Science Fiction</span>
</a>
<meta itemprop="position" content="3" />
</li>
<li itemprop="itemListElement" itemscope itemtype="https://schema.org/ListItem">
<span itemprop="name" aria-current="page">Award Winners</span>
<meta itemprop="position" content="4" />
</li>
</ol>
</nav>