Coding

JavaScript Can Change HTML Attributes – JavaScript Tutorial

Method Name

getElementById

Method Definition

This example changes an HTML image by changing the src (source) attribute of an tag:

Example


Try It Yourself - Online Compliler >>