I can create a json script with my questions + answers and copy it anywhere on my page, if i heard well. That's works like that :
<script type="application/ld+json"> { "@context": "https://schema.org", "@type": "FAQPage", "mainEntity": [{ "@type": "Question", "name": "What is the return policy?", "acceptedAnswer": { "@type": "Answer", "text": "Most unopened items in new condition and returned within <strong>90 days</strong> will receive a refund or exchange. Some items have a modified return policy noted on the receipt or packing slip. Items that are opened or damaged or do not have a receipt may be denied a refund or exchange. Items purchased online or in-store may be returned to any store.<br /><p>Online purchases may be returned via a major parcel carrier. <a href=http://example.com/returns> Click here </a> to initiate a return.</p>" } }, { "@type": "Question", "name": "How long does it take to process a refund?", "acceptedAnswer": { "@type": "Answer", "text": "We will reimburse you for returned items in the same way you paid for them. For example, any amounts deducted from a gift card will be credited back to a gift card. For returns by mail, once we receive your return, we will process it within 4–5 business days. It may take up to 7 days after we process the return to reflect in your account, depending on your financial institution's processing time." } }, { "@type": "Question", "name": "What is the policy for late/non-delivery of items ordered online?", "acceptedAnswer": { "@type": "Answer", "text": "Our local teams work diligently to make sure that your order arrives on time, within our normaldelivery hours of 9AM to 8PM in the recipient's time zone. During busy holiday periods like Christmas, Valentine's and Mother's Day, we may extend our delivery hours before 9AM and after 8PM to ensure that all gifts are delivered on time. If for any reason your gift does not arrive on time, our dedicated Customer Service agents will do everything they can to help successfully resolve your issue. <br/> <p><a href=https://example.com/orders/>Click here</a> to complete the form with your order-related question(s).</p>" } }, { "@type": "Question", "name": "When will my credit card be charged?", "acceptedAnswer": { "@type": "Answer", "text": "We'll attempt to securely charge your credit card at the point of purchase online. If there's a problem, you'll be notified on the spot and prompted to use another card. Once we receive verification of sufficient funds, your payment will be completed and transferred securely to us. Your account will be charged in 24 to 48 hours." } }, { "@type": "Question", "name": "Will I be charged sales tax for online orders?", "acceptedAnswer": { "@type": "Answer", "text":"Local and State sales tax will be collected if your recipient's mailing address is in: <ul><li>Arizona</li><li>California</li><li>Colorado</li></ul>"} }] } </script>
But, it's twice more work because i have to set my toggles and more set this script...
So, i would prefer to modify the toggles code and make the salient toggles rich content as clean as possible. I want modify it adding the Required propertie Google created for it, like you can see here:
<div itemscope itemprop="mainEntity" itemtype="https://schema.org/Question"> <h3 itemprop="name">What is the return policy?</h3> <div itemscope itemprop="acceptedAnswer" itemtype="https://schema.org/Answer"> <div itemprop="text"> Most unopened items in new condition and returned within <strong>90 days</strong> will receive a refund or exchange. Some items have a modified return policy noted on the receipt or packing slip. Items that are opened or damaged or do not have a receipt may be denied a refund or exchange. Items purchased online or in-store may be returned to any store. <br /><p>Online purchases may be returned via a major parcel carrier. <a href="http://example.com/returns"> Click here </a> to initiate a return.</p> </div> </div> </div>
Do you think i can do that ? and where can i modify this/these files in the salient directory ? Where have i to duplicate this file (that i will modify) in my salient-child theme ?
I think this subject could interest some other people so i make it public.
Please stop me if there is an easier and simple way to create these rich content !
Hi Tahir,
I want to make my FAQ section in each page rich content as Google defined it here https://developers.google.com/search/docs/data-types/faqpage.
Two options are explained,
I can create a json script with my questions + answers and copy it anywhere on my page, if i heard well. That's works like that :
But, it's twice more work because i have to set my toggles and more set this script...
So, i would prefer to modify the toggles code and make the salient toggles rich content as clean as possible. I want modify it adding the Required propertie Google created for it, like you can see here:
Do you think i can do that ? and where can i modify this/these files in the salient directory ? Where have i to duplicate this file (that i will modify) in my salient-child theme ?
I think this subject could interest some other people so i make it public.
Please stop me if there is an easier and simple way to create these rich content !
Thanks by advance,
Romain
Hey Romain!
As of now, this would require modifying the file. As of version 12, the Salient page builder elements can be overridden easily in a child theme. Check out the docs here: http://themenectar.com/docs/salient/overriding-salient-wpbakery-element-template-files-through-a-child-theme/
The file you're looking for is located at wp-content/plugins/salient-core/includes/vc_templates/toggle.php
Hi,
Thanks for your answer!I correctly dealed with the toggle.php duplication in a child theme and it works !
But still, Google doen't consider my content as rich content, as i verified on their own rich content page test (https://search.google.com/test/rich-results). I tried to modify reading thei instructions here (https://developers.google.com/search/docs/data-types/faqpage).
I wanrted to show you my process but i canno't upload php file here so i copied pasted it on a google sheet:
https://docs.google.com/document/d/1wrqmtIRQ27vPP3l6tlLiskrgKo8dcHXoHF5mwMDhiAo/edit?usp=sharing
You would have
PART 1: Your original code
PART 2: The Google instructions including some properties in tags
PART 3: The mix of you code and the google instructions.
What do you think should work ? Why did i do wrong ? I also tried something simple (removing 1 or 2 div, first of all but it didn't work neither...)
Thanks by advance for your help.
Romain