From 33058f2b292b3a581333bdfb21b8f671898c5060 Mon Sep 17 00:00:00 2001 From: Peter Bengtsson Date: Tue, 8 Dec 2020 14:40:17 -0500 Subject: initial commit --- .../ja/web/api/navigatorplugins/plugins/index.html | 59 ++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 files/ja/web/api/navigatorplugins/plugins/index.html (limited to 'files/ja/web/api/navigatorplugins/plugins/index.html') diff --git a/files/ja/web/api/navigatorplugins/plugins/index.html b/files/ja/web/api/navigatorplugins/plugins/index.html new file mode 100644 index 0000000000..fa0e482b6d --- /dev/null +++ b/files/ja/web/api/navigatorplugins/plugins/index.html @@ -0,0 +1,59 @@ +--- +title: window.navigator.plugins +slug: Web/API/NavigatorPlugins/plugins +tags: + - DOM + - DOM_0 + - Gecko +translation_of: Web/API/NavigatorPlugins/plugins +--- +
{{ApiRef}} {{non-standard_header}}
+ +

概要

+ +

アプリケーションにインストールされたプラグインをリスト化した、{{domxref("PluginArray")}} オブジェクトを返します。

+ +

構文

+ +
plugins = navigator.plugins;
+
+ + + +

戻り値は JavaScript の配列ではありませんが、length プロパティを持っています。また、各要素にアクセスする方法として、item(index )namedItem("name" ) メソッド経由だけでなく、plugins[2] のように、角括弧を使う方法もサポートしています。

+ +

+ +

以下の例は、高位の文書のためにインストールされたプラグインについての情報を出力します。注意:Plugin オブジェクトに用意されているプロパティは namefilenamedescription です。

+ +
{{gecko_minversion_note("1.9.2", "Gecko 1.9.2 で version プロパティが追加されました。")}}
+ +
var L = navigator.plugins.length;
+
+document.write(
+  L.toString() + " Plugin(s)<br>" +
+  "Name | Filename | description<br>"
+);
+
+for(var i = 0; i < L; i++) {
+  document.write(
+    navigator.plugins[i].name +
+    " | " +
+    navigator.plugins[i].filename +
+    " | " +
+    navigator.plugins[i].description +
+    " | " +
+    navigator.plugins[i].version +
+    "<br>"
+  );
+}
+ +

注記

+ +

{{domxref("Plugin")}} オブジェクトは、ブラウザにインストールされた様々なプラグインについての情報を取得して表示する小さなインタフェースです。 プラグインの一覧は、ブラウザのアドレスバーに about:plugins と入力することでも閲覧可能です。

+ +

仕様

+ +

{{DOM0}}

-- cgit v1.2.3-54-g00ecf