Cards (7)

  • Introduction to the DOM
    • The Document Object Model (DOM) is the data representation of the objects that comprise the structure and content of a document on the web.
  • What is the DOM?
    • The Document Object Model (DOM) is a programming interface for web documents. It represents the page so that programs can change the document structure, style, and content. The DOM represents the document as nodes and objects; that way, programming languages can interact with the page.
  • What is the DOM?
    • A web page is a document that can be either displayed in the browser window or as the HTML source. In both cases, it is the same document but the Document Object Model (DOM) representation allows it to be manipulated. As an object-oriented representation of the web page, it can be modified with a scripting language such as JavaScript.
  • What is the DOM?
    • For example, the DOM specifies that the querySelectorAll method in this code snippet must return a list of all the <p> elements in the document:
    • All of the properties, methods, and events available for manipulating and creating web pages are organized into objects. For example, the document object that represents the document itself, any table objects that implement the HTMLTableElement DOM interface for accessing HTML tables, and so forth, are all objects.
  • What is the DOM?
    • The DOM is built using multiple APIs that work together. The core DOM defines the entities describing any document and the objects within it. This is expanded upon as needed by other APIs that add new features and capabilities to the DOM. For example, the HTML DOM API adds support for representing HTML documents to the core DOM, and the SVG API adds support for representing SVG documents.
  • The DOM:
  • CSRF Token:
    • A CSRF token, also known as a CSRF prevention token or synchronizer token, is a security measure used to mitigate CSRF attacks. It is a unique token generated by the server and included in forms or requests sent by the web application. When a user submits a form or performs an action, the CSRF token is also submitted with the request. The server then verifies that the CSRF token matches what was expected for that particular action. If the token does not match or is missing, the server can reject the request, preventing the CSRF attack.