Today, I learned basic event handling in Javascript. This picture shows you how Javascript event handling works. When we defined the event handler and registered it, we includes the event trigger in the code. When user or page action triggers the event, the event executes by Javascript. There are three types of events. Mouse events Keyboard events. Form events. This is just the reference we comm..
Today, I leanred is about the element postition in Javascript. In the Javascript, the posisiton property is used to specify the type of positioning. absolute: The element is removed from normal flow and positioned in relation to its nearest positioned ancestor (if no positioned ancestor, then in relation to the browser window). fixed: The element is fixed in a specific position in the window eve..
Modifying the DOM Changing an Element's style Changing the Content of any given element. DOM manipulation Methods How can we change an element's style?? The first method is by directy change the properties of the style property for that element. Here is the example: The second method is by changing its class using the className or classList properties. Like this: There was an exercise to get use..
What is "DOM" in javascript?? ๐คจ The DOM is an abstract model that defines the interface between HTML documents and application programs. An API What I understand is that HTML properties can be used as values in Javascript. In this picture, we can see the "type" and "address" are the values in Javascript. There is the picture like tree to represent the structure of DOM: I can see the inheritance ..