特殊公告 (SpecialAnnouncement) 結構化資料 (Beta 版)

許多機構 (例如政府機關、公衛機構和學校等) 可能需要發布會對時程和日常生活其他層面的造成影響的緊急公告 (例如 COVID-19 公告),包括設施關閉、活動延期,以及設立新醫療設施 (例如檢測中心)。以下是一些特殊公告範例:

  • 居家避疫命令公告
  • 關閉通知 (例如學校停課或大眾運輸暫停營運)
  • 政府補助公告 (例如失業給付、帶薪假或一次性紓困補助)
  • 檢疫隔離規範
  • 旅遊限制
  • 新的免下車檢測中心設立通知
  • 宣布現場活動改為線上舉行或取消的公告
  • 服務時間調整和購物限制公告
  • 疾病傳播統計資料和地圖
Google 搜尋中的特殊公告範例

如何導入特殊公告

有兩種方式可以導入特殊公告:

  • 在網頁中新增 SpecialAnnouncement 結構化資料 (建議做法):結構化資料是一種標準化格式,能夠提供網頁相關資訊並分類網頁內容。如果您是第一次使用結構化資料,請參閱這篇文章,進一步瞭解結構化資料的運作方式。
  • 透過 Search Console 提交公告內容:如果您沒有存取網站 HTML 的權限,或是因為需要快速提交公告而沒時間導入結構化資料,可以透過 Search Console 提交公告內容。這項工具僅適用於張貼後一個月內就會失效的短期公告。此外,您目前無法在 Search Console 中更新公告內容 (如果使用結構化資料則可以更新公告,藉此提供其他詳細資訊或延長公告日期)。

如何新增結構化資料

結構化資料是一種標準化格式,能夠提供網頁相關資訊並分類網頁內容。如果您是第一次使用結構化資料,請參閱這篇文章,進一步瞭解結構化資料的運作方式。

以下簡要說明如何建立、測試及發布結構化資料。

  1. 新增必要屬性。根據您使用的格式,瞭解要在網頁中的什麼位置插入結構化資料
  2. 遵循指南規範
  3. 使用複合式搜尋結果測試驗證程式碼,並修正所有重大錯誤。此外,我們也建議您修正工具中可能標記的任何非重大問題,因為這有助於改善結構化資料的品質 (但並非符合複合式搜尋結果的顯示條件)。
  4. 部署幾個包含結構化資料的網頁,並使用網址檢查工具測試 Google 轉譯網頁的情形。請確認 Google 可以存取您的網頁,且網頁並未遭到 robots.txt 檔案或 noindex 標記封鎖,也未設有登入規定。如果網頁看起來沒問題,您可以要求 Google 重新檢索您的網址
  5. 為了讓 Google 掌握日後的異動內容,建議您提交 Sitemap。您可以使用 Search Console Sitemap API 自動執行這項操作。

透過 Search Console 為網站提交特殊公告 (Beta 版)

透過這個方法,政府機關和官方公衛機構能夠為自身的官方網站提交重要的公告,特別適合無法使用結構化資料的機構使用,包括設施關閉、活動延期,以及設立新醫療設施 (例如檢測中心)。Google 搜尋可以根據這項資訊有效掌握您的網頁內容,除了能將您的網頁搜尋結果提供給相關使用者,也會一併顯示重要公告。

開啟公告提交工具

功能適用情況

您可能會發現需求條件或規範有所改變,而且您可能無法立即在 Google 搜尋中看到相關結果。請注意,這項工具是為了方便醫療和政府機構張貼公告而設。但您可以先提供結構化資料,也可透過 Search Console 提交公告內容,日後當這項功能正式上線後,Google 搜尋就能以正確的格式來顯示您的公告。這有助於 Google 瞭解特殊公告背後的資料。

範例

居家避疫公告

以下是會影響多個縣市的居家避疫公告範例。

JSON-LD


<html>
  <head>
    <title>Shelter-in-place announcement</title>
    <script type="application/ld+json">
    {
      "@context": "https://schema.org",
      "@type": "SpecialAnnouncement",
      "name": "Shelter-in-place for 3 California counties",
      "text": "As of 11:59 pm on March 17, 2020, all individuals in the 3 counties must strictly follow the provisions in this new Order. This new Order will be in effect through March 30, 2020.",
      "datePosted": "2020-03-17T08:00",
      "expires": "2020-03-24T23:59",
      "quarantineGuidelines": "https://example.org/california/shelter-in-place/",
      "diseasePreventionInfo": "https://example.org/california/prevention-tips/",
      "spatialCoverage": [
        {
          "type": "AdministrativeArea",
          "name": "San Francisco County, CA"
        },
        {
          "type": "AdministrativeArea",
          "name": "Marin County, CA"
        },
        {
          "type": "AdministrativeArea",
          "name": "Santa Clara County, CA"
        }
      ]
    }
    </script>
  </head>
  <body>
  </body>
</html>

微資料


<html itemscope itemprop="SpecialAnnouncement" itemtype="https://schema.org/SpecialAnnouncement">
<head>
  <title itemprop="name">Shelter-in-place for 3 California counties</title>
</head>
<body>
  <p itemprop="datePosted" content="2020-03-17T08:00">March 17, 2020</p>
  <meta itemprop="expires" content="2020-03-30T08:00" />
  <p itemprop="text">As of 11:59 pm on March 17, 2020, all individuals in the 3 counties must strictly follow the provisions in this new Order. This new Order will be in effect through March 30, 2020.</p>
  <p itemprop="quarantineGuidelines" content="https://example.org/california/shelter-in-place/"><a href="https://example.org/california/shelter-in-place/">Learn more</a>.</p>
  <meta itemprop="diseasePreventionInfo" content="https://example.org/california/prevention-tips/" />
  <div itemprop="spatialCoverage" itemtype="https://schema.org/AdministrativeArea" itemscope>
    <meta itemprop="name" content="San Francisco County, CA" />
    </div>
  <div itemprop="spatialCoverage" itemtype="https://schema.org/AdministrativeArea" itemscope>
    <meta itemprop="name" content="Marin County, CA" />
  </div>
  <div itemprop="spatialCoverage" itemtype="https://schema.org/AdministrativeArea" itemscope>
    <meta itemprop="name" content="Santa Clara County, CA" />
  </div>
</body>
</html>

在單一網頁顯示多項更新

以下是含有多個公告的單一更新網頁範例。

JSON-LD


<html>
  <head>
    <title>CA Updates on COVID-19</title>
    <script type="application/ld+json">
  [{
      "@context": "https://schema.org",
      "@type": "SpecialAnnouncement",
      "name": "Shelter-in-place for 3 California counties",
      "text": "<a href=https://example.org/california/executive-order-123>Executive order 123</a> requires residents to shelter-in-place through April 30. Additional disease prevention and quarantine guidelines are also available.",
      "datePosted": "2020-04-01T08:00",
      "expires": "2020-05-03T23:59",
      "quarantineGuidelines": "https://example.org/california/shelter-in-place",
      "diseasePreventionInfo": "https://example.org/california/prevention-tips",
      "spatialCoverage": [
        {
          "type": "AdministrativeArea",
          "name": "Santa Clara County, CA"
        },
        {
          "type": "AdministrativeArea",
          "name": "Marin County, CA"
        },
        {
          "type": "AdministrativeArea",
          "name": "Santa Clara County, CA"
        }
      ]
    },
  {
      "@context": "https://schema.org",
      "@type": "SpecialAnnouncement",
      "name": "New information regarding worker benefits during COVID-19",
      "text": "A new summary chart explains the benefits for workers that are impacted by COVID-19. <a href=https://example.org/california/summary-of-benefits>Learn more</a>.",
      "datePosted": "2020-03-30T08:00",
      "expires": "2020-04-06T23:59",
      "newsUpdatesAndGuidelines": "https://example.org/california/worker-benefits-covid-19",
      "spatialCoverage":
        {
          "type": "State",
          "name": "CA"
        }
    },
    {
      "@context": "https://schema.org",
      "@type": "SpecialAnnouncement",
      "name": "Updates on key federal changes to make food and health care more accessible",
      "text": "The Federal Government is making food and health care more accessible.",
      "datePosted": "2020-03-29T08:00",
      "expires": "2020-04-05T23:59",
      "newsUpdatesAndGuidelines": "https://example.org/california/food-health-guidelines",
      "diseasePreventionInfo": "https://example.org/california/prevention-tips",
      "spatialCoverage":
        {
          "type": "State",
          "name": "CA"
        }
      }
  ]
    </script>
  </head>
  <body>
  </body>
</html>

微資料


<html>
<head>
  <title itemprop="name">CA Updates on COVID-19</title>
</head>
<body>
<div itemscope itemprop="SpecialAnnouncement" itemtype="https://schema.org/SpecialAnnouncement">
  <h2 itemprop="name">Shelter-in-place for 3 California counties</h2>
  <meta itemprop="datePosted" content="2020-03-17T08:00" />
  <meta itemprop="expires" content="2020-03-30T08:00" />
  <p itemprop="text"><a href=https://example.org/california/executive-order-123>Executive order 123</a> requires residents to shelter-in-place through April 30. Additional disease prevention and quarantine guidelines are also available.</p>
  <p itemprop="quarantineGuidelines" content="https://example.org/california/shelter-in-place/"><a href="https://example.org/california/shelter-in-place/">Learn more</a>.</p>
  <meta itemprop="diseasePreventionInfo" content="https://example.org/california/prevention-tips/" />
  <div itemprop="spatialCoverage" itemtype="https://schema.org/AdministrativeArea" itemscope>
    <meta itemprop="name" content="San Francisco County, CA" />
    </div>
  <div itemprop="spatialCoverage" itemtype="https://schema.org/AdministrativeArea" itemscope>
    <meta itemprop="name" content="Marin County, CA" />
  </div>
  <div itemprop="spatialCoverage" itemtype="https://schema.org/AdministrativeArea" itemscope>
    <meta itemprop="name" content="Santa Clara County, CA" />
  </div>
</div>
<div itemscope itemprop="SpecialAnnouncement" itemtype="https://schema.org/SpecialAnnouncement">
  <h2 itemprop="name">New information regarding worker benefits during COVID-19</h2>
  <meta itemprop="datePosted" content="2020-03-30T08:00" />
  <meta itemprop="expires" content="2020-04-06T23:59" />
  <p itemprop="text">A new summary chart explains the benefits for workers that are impacted by COVID-19. <a href=https://example.org/california/summary-of-benefits>Learn more</a>.</p>
  <meta itemprop="newsUpdatesAndGuidelines" content="https://example.org/california/worker-benefits-covid-19" />
  <div itemprop="spatialCoverage" itemtype="https://schema.org/State" itemscope>
    <meta itemprop="name" content="CA" />
    </div>
</div>
<div itemscope itemprop="SpecialAnnouncement" itemtype="https://schema.org/SpecialAnnouncement">
  <h2 itemprop="name">Updates on key federal changes to make food and health care more accessible</h2>
  <meta itemprop="datePosted" content="2020-03-29T08:00" />
  <meta itemprop="expires" content="2020-04-05T23:59" />
  <p itemprop="text">The Federal Government is making food and health care more accessible.</p>
  <meta itemprop="newsUpdatesAndGuidelines" content="https://example.org/california/food-health-guidelines" />
  <meta itemprop="diseasePreventionInfo" content="https://example.org/california/prevention-tip" />
  <div itemprop="spatialCoverage" itemtype="https://schema.org/State" itemscope>
    <meta itemprop="name" content="CA" />
    </div>
</div>
</body>
</html>

政府補助公告

以下是政府針對小型企業提供新補助的公告範例。

JSON-LD


<html>
  <head>
    <title>New Paycheck Protection Program for small business</title>
    <script type="application/ld+json">
  {
    "@context": "https://schema.org",
    "@type": "SpecialAnnouncement",
    "name": "New Paycheck Protection Program for small business",
    "text": "Example Administration announces a new loan that helps small businesses keep their workforce employed during the Coronavirus (COVID-19) crisis.",
    "datePosted": "2020-03-30T08:00",
    "expires": "2020-04-24T23:59",
    "category": "https://www.wikidata.org/wiki/Q81068910",
    "spatialCoverage": {
      "type": "Country",
        "name": "US"
        },
    "governmentBenefitsInfo": {
      "@type": "GovernmentService",
      "name": "Paycheck Protection Program",
      "url":  "https://www.sba.gov/funding-programs/loans/coronavirus-relief-options/paycheck-protection-program-ppp"
        }
      }
    }
  }
    </script>
  </head>
  <body>
  </body>
</html>

微資料


<html itemscope itemprop="SpecialAnnouncement" itemtype="https://schema.org/SpecialAnnouncement">
<head>
  <title itemprop="name">New Paycheck Protection Program for small business</title>
</head>
<body>
  <meta itemprop="datePosted" content="2020-03-30T08:00" />
  <meta itemprop="expires" content="2020-04-24T23:59" />
  <p itemprop="text">Example Administration announces a new loan that helps small businesses keep their workforce employed during the Coronavirus (COVID-19) crisis.</p>
  <div itemprop="spatialCoverage" itemtype="https://schema.org/Country" itemscope>
    <meta itemprop="name" content="US" />
  </div>
  <div itemprop="governmentBenefitsInfo" itemtype="https://schema.org/GovernmentService" itemscope>
    <meta itemprop="url" content="https://www.example.gov/funding-programs/loans/coronavirus-relief-options/paycheck-protection-program-ppp" />
    <meta itemprop="name" content="US Small Business Administration" />
  </div>
</body>
</html>

學校停課公告

以下是學校停課公告的範例。

JSON-LD


<html>
  <head>
    <title>COVID-19 School Announcements</title>
    <script type="application/ld+json">
  {
    "@context": "https://schema.org",
    "@type": "SpecialAnnouncement",
    "name": "COVID-19 School Announcements",
    "text": "All schools will remain closed through a minimum of May 1 in alignment with school
    districts across all Bay Area counties.",
    "datePosted": "2020-03-17T08:00",
    "expires": "2020-03-24T23:59",
    "schoolClosuresInfo": "https://example-school-district.org/announcements/extended-closure-notice",
    "announcementLocation": {
      "@type": "CivicStructure",
      "name": "Example School",
      "url": "https://example-school.org/"
    }
  }
    </script>
  </head>
  <body>
  </body>
</html>

微資料


<html itemscope itemprop="SpecialAnnouncement" itemtype="https://schema.org/SpecialAnnouncement">
<head>
  <title itemprop="name">COVID-19 School Announcements</title>
</head>
<body>
  <p itemprop="datePosted" content="2020-03-17T08:00">March 17, 2020</p>
  <meta itemprop="expires" content="2020-03-30T08:00" />
  <p itemprop="text">All schools will remain closed through a minimum of May 1 in alignment with school districts across all Bay Area counties.</p>
  <p itemprop="schoolClosuresInfo" content="https://example-school-district.org/announcements/extended-closure-notice"><a href="https://example-school-district.org/announcements/extended-closure-notice">Learn more</a>.</p>
  <div itemprop="announcementLocation" itemtype="https://schema.org/CivicStructure" itemscope>
    <meta itemprop="name" content="Example School" />
    <meta itemprop="url" content="https://example-school.org/" />
  </div>
</body>
</html>

檢測設施公告

以下是檢測設施公告的範例。

JSON-LD


<html>
  <head>
    <title>COVID-19 testing facility announcement</title>
    <script type="application/ld+json">
    {
      "@context": "https://schema.org",
      "@type": "SpecialAnnouncement",
      "name": "Example Health Care announces COVID-19 testing facility",
      "text": "Example Health Care's same-day primary care program is offering drive-through testing, by appointment, for SARS-CoV-2, the coronavirus that causes COVID-19.",
      "datePosted": "2020-03-16T08:00",
      "expires": "2020-03-24T23:59",
      "gettingTestedInfo": "https://med.example.edu/news/covid-19-testing-facility.html",
      "announcementLocation" : {
        "@type": "CivicStructure",
        "name": "Example Health Care",
        "url": "https://examplehealthcare.org/"
        }
      }
    </script>
  </head>
  <body>
  </body>
</html>

微資料


<html itemscope itemprop="SpecialAnnouncement" itemtype="https://schema.org/SpecialAnnouncement">
<head>
  <title itemprop="name">Example Health Care announces COVID-19 testing facility</title>
</head>
<body>
  <p itemprop="datePosted" content="2020-03-17T08:00">March 17, 2020</p>
  <meta itemprop="expires" content="2020-03-30T08:00" />
  <p itemprop="text">Example Health Care's same-day primary care program is offering drive-through testing, by appointment, for SARS-CoV-2, the coronavirus that causes COVID-19.</p>
  <p itemprop="gettingTestedInfo" content="https://med.example.edu/news/covid-19-testing-facility.html"><a href="https://med.example.edu/news/covid-19-testing-facility.html">Learn more</a>.</p>
  <div itemprop="announcementLocation" itemtype="https://schema.org/CivicStructure" itemscope>
    <meta itemprop="name" content="Example Health Care" />
    <meta itemprop="url" content="https://examplehealthcare.org/" />
  </div>
</body>
</html>

指南規範

您必須遵守以下指南規範,才能讓公告在 Google 搜尋中呈現為特殊公告。

結構化資料類型定義

您的內容必須包含必要的屬性,才能在 Google 搜尋中以特殊公告的形式呈現。如果有相關資訊,建議您一併新增建議的屬性。

SpecialAnnouncement

schema.org 內提供 SpecialAnnouncement 的完整定義。SpecialAnnouncement 在 Schema.org 上仍處於開發階段,但您還是可以開始使用這項屬性。 Google 支援的屬性如下:

必要屬性
datePosted

DateTime

特殊公告的發布日期 (採用 ISO-8601 格式)。

name

Text

特殊公告的簡短標題。例如:"Stanford announces COVID-19 testing facility"

text 或指向其他資訊的特定屬性

您必須加入 text,或根據公告的主題,加入下列其中一個指向其他公告相關資訊的屬性:

建議屬性
announcementLocation

LocalBusinessCivicStructure

SpecialAnnouncement 相關聯的特定地點,例如特定檢測設施或有特殊營業時間的商家。如果是較大的地理區域 (例如宣布對整個區域實施檢疫隔離),建議使用 spatialCoverage

{
  "@context": "https://schema.org",
  "@type": "SpecialAnnouncement",
  "announcementLocation": {
    "@type": "CivicStructure",
    "name": "Palo Alto High School"
    "url":   "https://example-school.org/"
  }
}
announcementLocation.name

Text

公告內容主要涉及的地點名稱,例如檢測設施的名稱。

announcementLocation.url

URL

可供使用者進一步瞭解公告內容涉及地點的網址,例如說明檢測設施位置、服務時間和適用對象的網址。

diseasePreventionInfo

URLWebContent

疾病預防相關資訊 (如適用於公告)。

diseaseSpreadStatistics

URLWebContentDatasetObservation

與疾病傳播情形相關的統計資訊 (如適用於公告),可以是 WebContent、直接以 Dataset 描述,或資料集內的特定 Observation。如果提供 WebContent 網址,該網址的網頁也可能會包含其他標記。

expires

DateTime

內容失效日,採 ISO-8601 格式。在這個日期之後,內容就會下架或沒有用處。 如果您不知道內容何時會失效,請不要加入這個屬性。

gettingTestedInfo

URLWebContent

針對 MedicalCondition 接受檢測的相關資訊 (如適用於公告)。

governmentBenefitsInfo

GovernmentService

與新政府補助的相關資訊 (如適用於公告)。如果選擇使用 governmentBenefitsInfo,則必須新增下列屬性:

如需這些屬性運作方式的完整範例,請參閱政府補助公告範例

governmentBenefitsInfo.name

Text

政府補助的名稱。例如:"Paycheck Protection Program"

governmentBenefitsInfo.url

URL

政府補助的詳細資訊網址。

newsUpdatesAndGuidelines

URLWebContent

包含特殊公告最新消息和相關規範的網頁 (如適用於公告)。這可以是網站上包含 SpecialAnnouncement 標記的主網頁,但也可以是其他網頁。

publicTransportClosuresInfo

URLWebContent

與大眾運輸暫停營運相關的資訊 (如適用於公告)。

quarantineGuidelines

URLWebContent

與隔離規則相關的指南 (如適用於公告)。

schoolClosuresInfo

URLWebContent

與學校停課相關的資訊 (如適用於公告)。

spatialCoverage

Place

特殊公告內容主要涉及的地理區域 (如適用)。舉例來說,公告可能是會影響多個區域的居家避疫命令。 如果公告會同時影響某個區域和某個特定地點 (例如服務整個區域的圖書館因疫情關閉),請同時使用 spatialCoverageannouncementLocation

{
  "@context": "https://schema.org",
  "@type": "SpecialAnnouncement",
  "spatialCoverage": [
    {
    "type": "AdministrativeArea",
    "name": "San Francisco County, CA"
    },
    {
    "type": "AdministrativeArea",
    "name": "Marin County, CA"
    },
    {
    "type": "AdministrativeArea",
    "name": "Santa Clara County, CA"
    }
  ]
}
text

Text

特殊公告的文字摘要,可以包含連結和清單等 HTML 內容。有效的 HTML 標記包括:<h1><h6><br><ol><ul><li><a><p><div><b><strong><i><em>

例如:"Stanford Health Care's same-day primary care program is offering drive-through testing, by appointment, for SARS-CoV-2, the coronavirus that causes COVID-19."

travelBans

URLWebContent

與旅遊禁令相關的資訊 (如適用於公告)。

透過 Search Console 監控複合式搜尋結果

Search Console 這項工具能協助您監控網頁在 Google 搜尋中的成效。 Google 會主動將您的網頁納入搜尋結果,您無需為此申請使用 Search Console,但是您可以藉由這項服務瞭解並改善 Google 檢索您網站的方式。建議在下列情況查看 Search Console:

  1. 首次部署結構化資料後
  2. 發布新範本或更新程式碼後
  3. 定期分析流量

首次部署結構化資料後

在 Google 為網頁建立索引後,請透過相關的複合式搜尋結果狀態報告查看是否存在任何問題。理想情況下,有效項目會增加,但無效項目不會變多。如果您在結構化資料中發現問題,請依下列步驟操作:

  1. 修正無效項目
  2. 檢查線上網址,查看問題是否仍繼續發生。
  3. 透過狀態報告要求驗證

發布新範本或更新程式碼後

當您對網站進行大幅變更時,請留意結構化資料中無效項目是否增加。
  • 如果無效項目增加,代表您推出的新範本可能無法正常運作,或者您的網站採用新方式與現有範本互動,但效果不佳。
  • 如果有效項目減少,但錯誤並未隨之增加,代表您的網頁可能已不再內嵌結構化資料。請使用網址檢查工具找出問題的成因。

定期分析流量

透過成效報表分析您的 Google 搜尋流量。 這些資料會顯示您的網頁在 Google 搜尋中呈現為複合式搜尋結果的頻率、使用者點擊的頻率,以及您的搜尋結果平均排名。您也可以使用 Search Console API 自動提取這些結果。

疑難排解

如果無法順利導入結構化資料,或是偵錯時遇到困難,請參考下列資源。

  • 如果您使用內容管理系統 (CMS) 或者有他人代您處理網站事務,請向對方尋求協助。請務必將所有與問題相關的 Search Console 訊息都轉寄給對方,這些訊息會針對問題提供詳細說明。
  • Google 不保證採用結構化資料的功能一定會顯示在搜尋結果中。如要瞭解為何 Google 無法將您的內容顯示為複合式搜尋結果,請參閱結構化資料通用指南裡的常見原因清單。
  • 結構化資料可能含有錯誤。請查看結構化資料錯誤清單
  • 如果您的網頁遭到結構化資料專人介入處理處置,系統會忽略網頁上的結構化資料,但該網頁仍然會出現在 Google 搜尋結果中。請使用專人介入處理報告來修正結構化資料問題
  • 再次查看指南規範,確認您的內容是否符合規定。問題可能是因為垃圾內容或不當使用的標記所引起。不過,因為問題可能與語法無關,所以複合式搜尋結果測試無法找出問題所在。
  • 疑難排解:未出現複合式搜尋結果/複合式搜尋結果總數減少
  • 請等待一段時間,讓系統執行重新檢索和重新建立索引作業。在發布網頁後,Google 可能需要幾天時間才會找到網頁並進行檢索。如有關於檢索和索引建立作業的一般問題,請參閱 Google 搜尋檢索和索引常見問題
  • 前往 Google 搜尋中心論壇發文提問。