How to Import Glossary from the File
This tutorial provides an overview of importing a glossary from the file instead of typing them manually.
Before you start check tutorial requirements:
Block editor (Gutenberg)
JetEngine plugin installed and activated
Glossary is a feature of the JetEngine plugin, and it allows you to create a reusable list of items. With the manual input, you have to create the label and value for every item, and it could take some time, especially if the amount of items is a hundred or more. Instead, you could import a .csv or .json file with a list of countries, movie genres, or car types.
Login to the website’s WordPress Dashboard, go to JetEngine > JetEngine Dashboard > Glossaries, and press the “New Glossary” button.
Insert the name of the glossary into the Name bar.
The Data Source bar has two options:
- Set item manually. To find out how this option works, follow this tutorial;
- Get items from uploaded file. Choose this option if you want to import the items for the new glossary.
Let’s see what we’ve got in the other bars:
- File to Get Data From. Click on the “Select File” button and upload or get from Media Library a .csv or .json file with the list;
- Value Column. Type the column name (or key for JSON objects) from which you want to get the value. You could leave the bar empty to detect the value automatically. Be aware that column names are case-sensitive;
- Label Column. Type the column name (or key for JSON objects) from which you want to get the label. You could leave the bar empty to detect the label automatically. Be aware that column names are case-sensitive.
After all necessary actions, hit the “Save” button.
Glossary could be used:
- in JetEngine post types, custom content types, meta boxes, options pages, and forms (with Radio, Select, and Checkbox fields);
- in JetSmartFilters (also with Radio, Select, and Checkbox fields).
If you need more details on how to use glossaries with these plugins, check it out here.
That’s how the imported glossary will look in the post:
In this way, you could import and set up a list of items as a Glossary in JetEngine. With that feature, you can upload files with long and popular lists instead of typing every item manually.
You could check these files with the country list and check the Glossaries feature on your site in .csv and .json formats.