-
AuthorPosts
-
July 21, 2024 at 5:33 am #1462589
Hello,
How can i add structured data with Enfold without a plugin?
I add my script json in header.php just before </head>
Everything is OK with the google testing tool of structured data but i can’t see my strucutured data in the Google search console..This is my site : vernissageduvar.com
Thanks for your help!
July 21, 2024 at 8:56 pm #1462624an other question: Whats is the difference by making this : https://kriesi.at/support/topic/structured-data-html/#post-758419 or ading the script in header.php?
July 22, 2024 at 7:54 am #1462641Hi,
Thank you for the inquiry.
Using the hook as provided in the previous thread and manually adding the data to the template file are the same. Where did you get the structured data JSON code, or how do you structure it?
Best regards,
IsmaelJuly 22, 2024 at 10:31 am #1462661Hi, thanks for your answer!
This is the code i put in header.php juste before </head>
<script type="application/ld+json"> { "@context": "https://schema.org", "@type": "LocalBusiness", "image": [ "https://vernissageduvar.com/wp-content/uploads/2024/06/image-du-site-vernissage-du-var.jpg" ], "address": { "@type" : "PostalAddress", "streetAddress" : "13 Notre Dame des Anges", "addressLocality" : "Gonfaron", "addressRegion" : "Var", "addressCountry" : "FR", "postalCode" : "83590 " }, "description": "Nous réalisons pour vous les travaux de ponçage, sablage, rénovations , petite ébénisterie, peintures et vernissage sur tous supports. ", "logo": "https://vernissageduvar.com/wp-content/uploads/2024/07/Logo-du-site-vernissage-du-var.png", "name": "Vernissage du Var", "openingHoursSpecification": [ { "@type": "OpeningHoursSpecification", "dayOfWeek": [ "Monday", "Tuesday", "Wednesday", "Thursday", "Friday" ], "opens": "08:00", "closes": "18:00" }, { "@type": "OpeningHoursSpecification", "dayOfWeek": [ "Saturday", "Sunday" ], "opens": "08:00", "closes": "12:00" } ], "priceRange": "$$", "telephone": "0686721473", "url": "https://vernissageduvar.com", "geo": { "@type": "GeoCoordinates", "latitude": 43.31818189354868, "longitude": 6.2900818092288 }, "AggregateRating": { "@type": "AggregateRating", "itemReviewed": "Vernissage du Var", "ratingCount": 8, "ratingValue": 5 }, "review": [ { "@type": "Review", "author": { "@type": "Person", "name": "Elisabeth Hecketsweiler" }, "datePublished": "2024-06-21", "description": "Entreprise au top pour sa disponibilit\u00e9, son professionnalisme et ses tr\u00e8s bons conseils! Vraiment tr\u00e8s satisfaite du travail effectu\u00e9! Je ne reconnais plus mes meubles de cuisine! Nous referons appel \u00e0 Vernissage du Var les yeux ferm\u00e9s si besoin et nous les recommanderons autour de nous.", "name": "Vernissage du Var", "reviewRating": { "@type": "Rating", "bestRating": 5, "ratingValue": 5, "worstRating": 1 } }, { "@type": "Review", "author": { "@type": "Person", "name": "Pierre MARTIN" }, "datePublished": "2024-07-15", "description": "On voit tout de suite qu'on a affaire a un passionn\u00e9! un travail m\u00e9ticuleux pour un tarif tr\u00e8s raisonnable, les d\u00e9lais ont \u00e9t\u00e9 respect\u00e9s, je recommande sans aucune h\u00e9sitation!", "name": "Vernissage du Var", "reviewRating": { "@type": "Rating", "bestRating": 5, "ratingValue": 5, "worstRating": 1 } }, { "@type": "Review", "author": { "@type": "Person", "name": "S\u00e9bastien Hazebroucq" }, "datePublished": "2024-06-21", "description": "Au top.\nJe vous conseille vivement de jeter un oeil.\nTr\u00e8s beau boulot.", "name": "Vernissage du Var", "reviewRating": { "@type": "Rating", "bestRating": 5, "ratingValue": 5, "worstRating": 1 } }, { "@type": "Review", "author": { "@type": "Person", "name": "Djamila Sahki" }, "datePublished": "2024-06-21", "description": "Travail tr\u00e8s s\u00e9rieux je suis contente de son professionnalisme et pontuel je le conseille", "name": "Vernissage du Var", "reviewRating": { "@type": "Rating", "bestRating": 5, "ratingValue": 5, "worstRating": 1 } }, { "@type": "Review", "author": { "@type": "Person", "name": "Sebastien Ramuscello" }, "datePublished": "2024-06-21", "description": "Tres bon acceuil bon professionnel et tres reactif ! Je recommande sans hesitation.sebastien", "name": "Vernissage du Var", "reviewRating": { "@type": "Rating", "bestRating": 5, "ratingValue": 5, "worstRating": 1 } } ] } </script>
I don’t have error when i test it with google tools but the problem is that i don’t find it in the search console
Thanks for your help!
July 22, 2024 at 10:57 am #1462666Hi,
Thank you for the info.
The testing tools seem to be returning the correct results.
// https://validator.schema.org/#url=http%3A%2F%2Fvernissageduvar.com
// https://search.google.com/test/rich-results/result/r%2Flocal-business?id=Fdx0U3fC4N8bGDj5QSsTDgWe are not really sure why it’s not showing up in your console. Have you finished verifying the site and claimed your business profile on Google? Please check the links below:
// https://support.google.com/knowledgepanel/answer/7534902
// https://support.google.com/business/answer/2911778Best regards,
IsmaelJuly 22, 2024 at 11:49 am #1462668Hello,
i cheked everything, google console, wordpress, google my business and everything seems to be ok..
I use Yoast SEO but i desactivated structured data with this:add_filter( ‘wpseo_json_ld_output’, ‘__return_false’ );` in functions.php
If Yoast is activated by deleting this filter, i can see Yoast structured data in the search console.
It seems that my code is not visible by Google…
Do i have to wait ?
July 23, 2024 at 3:41 am #1462728Hi,
Thank you for the info.
When you manually add schema code to the header.php file, it is applied to every page, which may not always be appropriate and could lead to errors. This might be why Google is not recognizing it correctly. We recommend removing the manual code and using the options available in the Yoast plugin or a dedicated schema plugin such as the one listed below.
// https://wordpress.org/plugins/schema/
Best regards,
IsmaelJuly 23, 2024 at 6:28 am #1462738Hello,
In Yoast plugin, there is no so much informations available… they don’t have the schema type “local business”.
With Enfold it’s the same, there is no so much informations available..
So as i told you, i would like to add my structured data without plugin..Moreover, the plugin “Schema” you told me about is not updated since 8 months…and anyway, local business is only in the premium version so thanks!One more information, i use the plugin reviews and rating that is great for reviews and i desactived stuctured data from this plugin because i wanted to have only one file. I reactivate stuctured data from this plugin and i saw that now i have in double reviews in the Google testin tool of structured data. So my file seems to be half seen…
What is the best way for you to add code in the header of a spécific page?
There is not a way to add my personnal structured data to Enfold ones?- This reply was modified 4 months ago by pierremartin311.
July 23, 2024 at 10:58 am #1462757Hi,
Thank you for the info.
As mentioned above, it doesn’t matter if you use the wp_head hook or directly place the schema in the template file, as long as it’s inside the head tag or at the bottom of the body tag. Unfortunately, we are not sure why it’s not showing in your console. If you recently added or updated the JSON-LD, Google might not have crawled your site yet. You can try to request indexing through the search console
// https://developers.google.com/search/docs/crawling-indexing/ask-google-to-recrawl
Also, here’s a cleaned-up version of the schema, with line breaks removed and key casings fixed: https://pastebin.com/9aaVaEfZ
Best regards,
IsmaelJuly 29, 2024 at 7:29 am #1463202Good morning,
Even after waiting, my structured data entered in the <head> is not recognized by Google. So I reactivated the incomplete structured data from Yoast and the Enfold theme.
I find incredible that there is not a way to add our own structured data provided in your theme.. The only solution you told me about is a plugin not updated for 8 months..
Am I the first who want to include local business structured data for my site?Best regards
July 30, 2024 at 5:59 am #1463289Hi,
Thank you for the update.
Am I the first who want to include local business structured data for my site?
There have been many requests about this, but most users choose to use a plugin such as Yoast or the one we recommended above. Nothing has really changed in how schema structures are added to the site, so even though the plugin hasn’t been updated for 8 months, it should still work fine. Also, please note that the theme already includes a basic schema structure for the site.
Best regards,
Ismael -
AuthorPosts
- You must be logged in to reply to this topic.