Vidyalelo
JavaScript · Q7

Animation

Programming · JavaScript · question 7

Q7

How to assign the image source in JavaScript?

A.
image = “url”
B.
source(“url”)
C.
image.src = “url”
Answer
D.
none of the mentioned

Answer: Option C

Solution

Answer: Option C
Solution:
The image source is defined as image.src = “/images/html.gif”.