Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <script>
- window.onload=function(){
- document.getElementById("area").addEventListener("click", function(){
- document.getElementById("callout").innerHTML = "click";
- });
- document.getElementById("area").addEventListener("touchstart", function(){
- document.getElementById("callout").innerHTML = "touchstart";
- });
- document.getElementById("area").addEventListener("touchend", function(){
- document.getElementById("callout").innerHTML = "touchend";
- });
- document.getElementById("area").addEventListener("touchmove", function(){
- document.getElementById("callout").innerHTML = "touchmove";
- });
- }
- </script>
- <body id="touchy">
- <div id ="area" style="background-color:#ff0000; height:200px;"></div>
- <div id="callout"></div>
- </body>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement