Guest User

Untitled

a guest
Sep 3rd, 2015
73
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="UTF-8">
  5. <title>Content</title>
  6. </head>
  7. <body>
  8. <div>
  9. <div id="atom1" contenteditable="true">
  10. atom
  11. </div>
  12. </div>
  13. <script>
  14. var atom = document.getElementById("atom1")
  15. atom.addEventListener('focus', function(event) {
  16. console.log('focus' + event.target.id)
  17. })
  18. atom.addEventListener('blur', function(event) {
  19. console.log('blur' + event.target.id)
  20. })
  21. atom.addEventListener('input', function(event) {
  22. //outputs in all browsers except IE11
  23. console.log('input' + event.target.id)
  24. })
  25. </script>
  26. </body>
  27. </html>
RAW Paste Data

Adblocker detected! Please consider disabling it...

We've detected AdBlock Plus or some other adblocking software preventing Pastebin.com from fully loading.

We don't have any obnoxious sound, or popup ads, we actively block these annoying types of ads!

Please add Pastebin.com to your ad blocker whitelist or disable your adblocking software.

×