This demonstates a simple getElementsByClassName JS function. The script will run onload, find all the elements within the above div and make those with the "random" class clickable. Passing of a parent node is optional - if none is passed, the document root will be used. Tag filtering is also optional - if no specified tag name is passed, all tags will be searched. If a browser supports native getElementsByClassName, it will be used.