A Pen by lfernandez55 on CodePen.
Last active
February 25, 2020 04:26
-
-
Save lfernandez55/08fdada031b45fdc961e432bfd4f6fa2 to your computer and use it in GitHub Desktop.
Evolve 1st Day Demos
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <meta charset="utf-8"> | |
| <meta name="viewport" content="width=device-width"> | |
| <title></title> | |
| </head> | |
| <body> | |
| <div id="myid">aaa</div> | |
| <table> | |
| <tr> | |
| <td id="myTableId">ddddd</td> | |
| <td></td> | |
| <td></td> | |
| <td></td> | |
| <td></td> | |
| </tr> | |
| <tr> | |
| <td></td> | |
| <td></td> | |
| <td></td> | |
| <td></td> | |
| <td></td> | |
| </tr> | |
| <tr> | |
| <td></td> | |
| <td></td> | |
| <td></td> | |
| <td></td> | |
| <td></td> | |
| </tr> | |
| <tr> | |
| <td></td> | |
| <td></td> | |
| <td></td> | |
| <td></td> | |
| <td></td> | |
| </tr> | |
| <tr> | |
| <td></td> | |
| <td></td> | |
| <td></td> | |
| <td></td> | |
| <td></td> | |
| </tr> | |
| </table> | |
| </body> | |
| </html> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| document.getElementById('myDiv').addEventListener("click",foo) | |
| function foo(){ | |
| alert("Foo!") | |
| } | |
| document.getElementById('myTableId').addEventListener("click",function(){ | |
| doit(this) | |
| }) | |
| function doit(elem){ | |
| console.log(elem.innerHTML) | |
| elem.style.backgroundColor="aqua" | |
| console.log(this.row) | |
| } | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| tr,td{ | |
| border:1px solid | |
| black; | |
| padding:10px | |
| } | |
| table{ | |
| border-collapse:collapse | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment