editing src of img in js code example Example: how to change image source using javascript document.getElementById("myImg").src = "hackanm.gif";