Advertisement
Guest User

js string

a guest
Sep 1st, 2015
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <html>
  2. <body>
  3. <p id="home" onMouseOver="myFunction()">hello world hello delhi</p>
  4. <script>
  5. var a=document.getElementById("home").innerHTML;
  6.  
  7. function myFunction()
  8. {
  9.    
  10.     var b="hello mumbai";
  11.     document.getElementById("home").innerHTML=a.concat(" ",b);
  12.    
  13.     }
  14.  
  15. </script>
  16. </body>
  17. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement