StefiIOE

removing text on click

Jun 20th, 2020
842
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4.     <script src = "jquery-3.5.1.min.js"></script>
  5.     <script>
  6.         $(document).ready(function () {
  7.             $("p").click(function () {
  8.                 $(this).hide();
  9.  
  10.             });
  11.  
  12.         });
  13.     </script>
  14. </head>
  15. <body>
  16. <p>If you click me i will disappear.
  17. </p>
  18. <p>Click me too.</p>
  19. <p>Don't forget me :)</p>
  20. </body>
  21. </html>
RAW Paste Data