call a javascript function in html with object id code example Example: get element by id in javascript document.getElementById("YourElementId");