谷歌搜索中为了吸引用户访问有一种特别的数据化结构就是常见问答,从而激发其他用户链接到您网站的兴趣。Google 十分擅长检测各种违反我们的网站站长指南的非自然链接(例如,来自链接交换方案/付费链接方案的链接或自动生成的链接),因此参与这样的方案可能会弊大于利。比如下图:
网站在搜素引擎中展示常见问答的样式如下:
你可以在你的wordpress新增问答自定字段,也可以在前端调用它,比如豆丁博客网站最近新增了这个样式(如下图):
添加常见问答数据结构
结构化数据是一种提供网页相关信息并对网页内容进行分类的标准化格式。下面概述了如何构建、测试和发布结构化数据。FAQ 富媒体搜索结果目前适用于所有可以使用 Google 搜索的国家/地区和语言,既支持桌面设备,也支持移动设备。实现代码如下:
<html> <head> <title>Example Site - Frequently Asked Questions(FAQ)</title> <script type="application/ld+json"> { "@context": "https://schema.org", "@type": "FAQPage", "mainEntity": [{ "@type": "Question", "name": "What is the return policy?", "acceptedAnswer": { "@type": "Answer", "text": "<p>Most unopened items in new condition and returned within <b>90 days</b> 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.</p><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": "<p>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.</p><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> </head> <body> </body> </html>
如果部署一些包含结构化数据的网页后, 你可以通过使用富媒体搜索结果测试验证您的代码,是否正确。