HTML DOM document plugins Property

The HTML DOM plugins property returns an HTMLCollectionobject containing one or more embed elements or plugins of the current document. This is a read-only property.

Syntax:

objects = document.plugins

Return value:

An HTMLCollection object, or “null” object,if there are no embedded elements or plugins in the document.



Example: This example shows how to get plugins of the document.

HTML

filter_none

edit
close

play_arrow

link
brightness_4
code

<!DOCTYPE html>
<html>
  
<head>
    <title>
        HTML DOM document 
        plugins property
    </title>
</head>
  
<body>
    <h1>GeeksforGeeks</h1>
    <embed src="hello.PNG">
    <embed src="hello.PNG">
    <br>
  
    <button onclick="get()">
        CLICK HERE
    </button>
      
    <script type="text/javascript">
        function get() {
            console.log(document.plugins);
        }
    </script>
</body>
  
</html>

chevron_right


Output:

  • Before Click the Button:

  • After Click the Button:

Supported browsers:

  • Google Chrome
  • Internet Explorer
  • Firefox
  • Opera
  • Safari

full-stack-img

My Personal Notes arrow_drop_up

Check out this Author's contributed articles.

If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to contribute@geeksforgeeks.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.

Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.