このページはコミュニティーの尽力で英語から翻訳されました。MDN Web Docsコミュニティーについてもっと知り、仲間になるにはこちらから。
HTMLAreaElement: ping プロパティ
Limited availability
This feature is not Baseline because it does not work in some of the most widely-used browsers.
ping はHTMLAreaElement インターフェイスのプロパティで、 URL を空白で区切ったリストです。このリンクを辿ると、ブラウザーは PING を本体としたPOST リクエストをその URL に送信します。
これは<area> 要素のping 属性を反映します。
メモ:このプロパティは Firefox では有効ではなく、プライバシーおよびセキュリティ上の理由により使用が制限されている場合があります。
In this article
例
html
<map> <area href="https://example.com" ping="https://example-tracking.com https://example-analytics.com" alt="example" /></map>js
const areaCollection = document.getElementsByTagName("map")[0].areas;console.log(areaCollection[0].ping); // 出力: "https://example-tracking.com https://example-analytics.com"仕様書
| Specification |
|---|
| HTML> # dom-area-ping> |
ブラウザーの互換性
関連情報
HTMLAnchorElement.pingプロパティ