PHP Classes

File: templates/local_business.tpl

Recommend this page to a friend!
  Classes of TJ Webb   WordPress ACF Smarty Posts LocalBusiness Schema   templates/local_business.tpl   Download  
File: templates/local_business.tpl
Role: Auxiliary data
Content type: text/plain
Description: Auxiliary data
Class: WordPress ACF Smarty Posts LocalBusiness Schema
Add LocalBusiness meta data to WordPress site page
Author: By
Last change:
Date: 1 year ago
Size: 1,932 bytes
 

Contents

Class file image Download
<script type="application/ld+json"> { "@context" : "http://schema.org", "@type" : "{$type}", "address" : { "@type" : "PostalAddress", "addressLocality" : "{$city}", "addressRegion" : "{$province}", "streetAddress" : "{$streetAddress}", "postalCode" : "{$postal_code}", "telephone" : "{$local_phone}", "addressCountry" : "{$country}" } , {if $fax} "faxNumber" : "{$fax}", {/if} {if $toll_free_phone} "telephone" : "{$toll_free_phone}", {else} "telephone" : "{$local_phone}", {/if} "description" : "{$description}", "name" : "{$name}", "geo" : { "@type": "GeoCoordinates", "address" : { "@type" : "PostalAddress", "addressLocality" : "{$city}", "addressRegion" : "{$province}", "streetAddress" : "{$address_1}", "postalCode" : "{$postal_code}", "telephone" : "{$local_phone}", "addressCountry" : "{$country}" }, "addressCountry" : "{$country}", "postalCode" : "{$postal_code}", "latitude" : "{$latitude}", "longitude" : "{$longitude}" } , "image" : "{$image}", "logo" : "{$logo}", "hasMap" : "{$map_url}", "openingHours" : [ {foreach from=$hours item=hour name=openingHours} "{$hour.day} {$hour.open_at}-{$hour.close_at}"{if not $smarty.foreach.openingHours.last},{/if} {/foreach} ], "sameAs" : [ {foreach from=$connect_sites item=site name=sameAs} "{$site.url}"{if not $smarty.foreach.sameAs.last},{/if} {/foreach} ], "url" : "{$url}" } </script>