Tryit Editor v2.3

Edit This Code:
<!DOCTYPE html> <html> <body> <img id="image" src="smiley.gif" width="160" height="120"> <script> document.getElementById("image").src = "landscape.jpg"; </script> <p>The original image was smiley.gif, but the script changed it to landscape.jpg</p> </body> <!-- Mirrored from www.w3schools.com/js/tryit.asp?filename=tryjs_dom_image by HTTrack Website Copier/3.x [XR&CO'2014], Fri, 23 Jan 2015 07:36:28 GMT --> </html>
Result:
Try it Yourself - © w3schools.com