previous | index | next

Accessing HTML DOM Nodes from JavaScript

  1. In JSF page: use the id attribute to give an element a unique identifier
  2. In JavaScript function: use window.document to access the document node

  3. Use window.document.getElementById() to get the element you want to manipulate

previous | index | next