/* event listener */
document.getElementsByName("Thing")[0].addEventListener('change', doThing);
/* function */
function doThing(){
alert('Horray! Someone wrote "' + this.value + '"!');
}
window.onload = function() {
[].forEach.call(document.querySelectorAll('.content[href="this.com"]'),function(e){
e.innerHTML = "Im changed by forEach, its still a loop!";
});
}
function addEventHandler(elem, eventType, handler) {
if (elem.addEventListener)
elem.addEventListener (eventType, handler, false);
else if (elem.attachEvent)
elem.attachEvent ('on' + eventType, handler);
}