Answers for "dynamic img url"

0

dynamic img url

function dynamicUrl() {
  var url = "https://is1-ssl.mzstatic.com/image/thumb/Purple111/v4/dd/95/7e/dd957e3a-abd3-da8a-2211-726a67108938/source/256x256bb.jpg";
  return url;
}

var img = document.createElement("img");
img.src = dynamicUrl();
document.body.appendChild(img);
 Run code snippet
Posted by: Guest on October-13-2021

Code answers related to "Javascript"

Browse Popular Code Answers by Language