Star Selectors Example in JQuery


A symbolic star. Returns Like any other jQuery selector, this selector also returns an array filled with the found elements. Example $('*') selects all the elements

Source Code

<!DOCTYPE html>
<html lang="en">
  <head>
    <title>Star Selector Example</title>
    <!--------META-------->
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    
    <!------JQUERY CDN---->
    <script src="https://code.jquery.com/jquery-3.5.1.min.js"></script>
  </head>
  <body>
    <h3>Star Selector Example</h3><hr>
    <p>Lorem ipsum, or lipsum as it is sometimes known, is dummy text used in laying out print, 
	graphic or web designs. The passage is attributed to an unknown typesetter in the 15th 
	century who is thought to have scrambled parts of Cicero's De Finibus Bonorum et Malorum 
	for use in a type specimen book.</p>
    
    <button type="button">Click to hide all </button>
    
    <script>
      $(document).ready(function()
      {
      	$("button").click(function()
      	{
      	  $("*").hide();
      	});
      });
    </script>
  </body>
</html>
To download raw file Click Here

Learn All in Tamil © Designed & Developed By Tutor Joes