Yext Knowledge Tags allows you to add schema as well as easily sync entity information from Yext to your website. This article explains how to add Knowledge Tags to your website if you use WordPress.
Step 1: Install the Knowledge Tags from Yext Wordpress Plugin
- Log into your Wordpress account.
- Hover over Plugins in the left sidebar and click Add New.
- Search for the Knowledge Tags from Yext Plugin and click Install Now.
- Once it is installed, click Knowledge Tags from Yext in the left sidebar.
- Retrieve the Knowledge Tags Key from the Yext platform to activate the plugin.
- From your Yext account click Pages in the top navigation bar.
- Click on the Knowledge Tags sub-tab.
- Click on the Add Knowledge Tags to Website button. A dialog box appears.
- Copy the Key.
- In your Wordpress account, enter the key into the Key text box and click Save Settings.
Step 2: Enable Custom Fields in WordPress
Custom Fields must be enabled in Wordpress in order to enable schema. Custom fields need to be added to each Wordpress page that you would like to add schema to.
- Navigate to the Edit page for the specific Wordpress page you would like to add schema to.
- Click on the three dots in the upper-right corner of the page and select Options from the drop-down menu. A dialog box appears.
- Check the box next to Custom Fields.
- Once Custom Fields is enabled, enter the custom field at the bottom of the page.
- Enter "yext-knowledge-tags-location-id” as the name of the custom field, and add your Entity ID as the value of the field.
- To access your entity ID click Knowledge Graph in your Yext account and click into the desired Entity. The Entity ID will be listed under the Featured Message. To export Entity IDs in bulk, see export entities.
- Click Add Custom Field.
- Once you’ve added the Custom Field click Update in the top right corner.
- Verify that schema was installed correctly.
- Visit Google’s Structured Data Testing Tool.
- Enter a URL into the text box, and click RUN TEST.
- Note: If schema is successfully installed, you will see your entity information listed in the right panel of the Google Structured Testing Tool.
- Repeat for each page you would like to add schema to.
Please Note: You will need to have this code embedded on the page before you can use the Knowledge Sync feature.
(Optional) Set up Knowledge Sync
Knowledge Sync is an optional feature that allows you to display content from your Yext account directly on your website. Once installed, any changes you make in Yext will dynamically update on your website and Listings to keep everything consistent and up-to-date. Knowledge Sync does not affect schema, but it allows you to add structured data to your website, and manage your information all in one place.
- Click into the Knowledge Tags for Yext Wordpress Plugin.
- Copy the field name for the content you would like to add.
- Configure the shortcode.
- Make sure the Entity ID corresponds to whichever entity you would like to pull content from. The shortcode should follow this format: [yext-data yext-location-id=ID yext-field=fieldname]
- For a full list of fields and their corresponding field names see Working with Knowledge Tags.
- Click in to edit the specific page.
- Paste the shortcode wherever you would like this content to appear on the page.