What does dot in js indicate. Equals signs are assigned to a variable. When there is content in the document, that is, the window is used for marking. onload is used to call a function for execution. Otherwise, the browser will not execute it. Generally, the script is placed before the </body> label to load the structure and style first, finally, load the script file, which is conducive to the user experience and the principle of accessibility.
Let's start with the first small instance today. In fact, it was done yesterday. Today it is pasted as =!
1 <! DOCTYPE html> 2
This is something similar to a prompt box. You will understand it and will not explain it. The label can be used to contain the input element. When you move the mouse over the text, the onmuoseover event will also occur.
The second small instance:
1 <!DOCTYPE html> 2
This instance uses className to change the class name to implement style switching. Pay special attention to every punctuation mark. If you have more Punctuation Marks, you will be wrong. In addition, the div in the style label cannot use # div1. Otherwise, an error may occur. I don't know what the problem is. I found it during debugging.
- This guy () must be added to the function call and can be used multiple times, similar to the class in css.
- GetElementByID ();
- Alert ();
- Onclick;
- Onmouseover/onmouseout;
- ClassName;
END !!