SNIP: Structured Data & Schema Plugin for WordPress › Forums › Structured Data Help › Recipe Data structure problems
April 25, 2021 at 6:51 pm #3569umut1989Participant
I have recipe page, and I am using a theme which does not have build in rich snippets. So I have been trying to add it with various plugins and I chose the SNIP plugin because I have a very specific problem. The meta data I have for recipeIngredients and recipeInstructions are inside an array. After googling I found this https://rich-snippets.io/how-to-work-with-custom-fields/ which is a solution to my problem. But it does not work at all. I can’t get my instruction or ingredients to show up at all. How can I resolve this issue?April 27, 2021 at 10:53 am #3570FlorianKeymaster
and thanks for your message.
There was a bug prior version 2.24.0 which caused an issue using arrows in the textfield of the Postmeta field type. So I would recommend up upgrade to the latest version first.
If the problem still persists, please post the structured of the array from the database.
Also please note that the data needs to be stored in the wp_postmeta database table. SNIP cannot access data from anywhere else at this point in time.
FloApril 27, 2021 at 8:04 pm #3572umut1989Participant
I have updated to the latest version, so that is not causing the issue.
Here is a screenshot of what it looks like in the database. It is in the wp_postmeta table.
When I try to get the table with another plugin it does show up in the Google Search Console. But with that plugin I can’t select the specific value I want.
When I try to select the metadata with SNIP it doesn’t show anything at all. I have tried doing “qodef_recipe_single_ingredients_items->qodef_recipe_single_ingredients_text” but with no luck.
UmutApril 27, 2021 at 8:40 pm #3576FlorianKeymaster
and thanks for the clarification.
I guess what you’re trying to achieve is to loop through the recipe items, correct? Unfortunately that doesn’t work. But you can access the single items. Try the following for the first item:
For the second item you do:
And so on.
Because you don’t know how much ingredients you have, I would ask a developer to build a custom loop for you which would it make it way easier for you.
- This reply was modified 1 year, 2 months ago by Florian.
- You must be logged in to reply to this topic.