Advertisement
Dexlogi22

Untitled

Jun 26th, 2022
1,078
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
HTML 0.39 KB | None
  1.  
  2.   <body>
  3.     <button onclick="togglesrc()">click here</button>
  4.     <p id="p">This a simple paragraph</p>
  5.     <button>click 2</button>
  6.   </body>
  7.  
  8.   <script>
  9.     var bt = document.querySelector("button");
  10.     var im = document.querySelector("img");
  11.  
  12.     function togglesrc(){
  13.  
  14.     let pa= document.getElementById("p");
  15.     pa.innerHTML= "klklk";
  16.    
  17.  
  18.  
  19.     }
  20.   </script>
  21. </html>
  22.  
Advertisement
RAW Paste Data Copied
Advertisement