LocalBusiness JSON-LD schema output on the front page and on pages. Free core feature. The AI Auto-Fill block of the Local SEO screen is the one Pro part: you type the business name, the city and what the business does, press Generate All Fields, and the AI fills in the business name, business type, phone, email, street, city, state, ZIP, country (a two-letter code), price range, opening hours and social profile URLs of the form where it has a value for them. It does not fill the latitude, the longitude, the logo URL or the image, and it does not read your site. It needs the Pro add-on with its AI features running. Nothing is output until enabled is on and a business_name is set.
Settings Structure
$settings = [
'enabled' => true,
'business_name' => 'My Restaurant',
'business_type' => 'Restaurant',
'phone' => '+1-555-123-4567',
'email' => '[email protected]',
'street' => '123 Main Street',
'city' => 'New York',
'state' => 'NY',
'zip' => '10001',
'country' => 'US',
'lat' => '40.7128',
'lng' => '-74.0060',
'opening_hours' => "Mo-Fr 09:00-17:00\nSa 10:00-14:00",
'price_range' => '$$',
'logo_url' => 'https://example.com/logo.png',
'image_url' => 'https://example.com/storefront.jpg',
'social_urls' => "https://facebook.com/mybiz\nhttps://twitter.com/mybiz",
];
update_option( 'rankforge_local_seo', $settings );The Local SEO screen has no field for image_url. A save from the screen keeps the value that code or an import stored there.
Available Business Types
$types = RANKFORGE_Local_Seo::get_business_types();
// Returns 30 types: 'Organization', 'ProfessionalService', 'LocalBusiness',
// 'Restaurant', 'Dentist', 'MedicalClinic', 'BeautySalon', 'AutoRepair', ...Schema Output
Output on wp_head (priority 6) for the front page and for pages, not for posts or archives. For the settings above it reads:
{
"@context": "https://schema.org",
"@type": "Restaurant",
"name": "My Restaurant",
"url": "https://example.com/",
"telephone": "+1-555-123-4567",
"email": "[email protected]",
"address": {
"@type": "PostalAddress",
"streetAddress": "123 Main Street",
"addressLocality": "New York",
"addressRegion": "NY",
"postalCode": "10001",
"addressCountry": "US"
},
"geo": {
"@type": "GeoCoordinates",
"latitude": "40.7128",
"longitude": "-74.0060"
},
"logo": "https://example.com/logo.png",
"image": "https://example.com/storefront.jpg",
"priceRange": "$$",
"openingHours": ["Mo-Fr 09:00-17:00", "Sa 10:00-14:00"],
"sameAs": ["https://facebook.com/mybiz", "https://twitter.com/mybiz"]
}—