This
OLCC programming example
page demonstrates getting a 2D drawing from
PubChem using JavaScript.
Press the "test" button to evaluate the JavaScript in the textarea below.
Feel free to modify the JavaScript and press test again.
var url = "https://pubchem.ncbi.nlm.nih.gov/rest/pug/compound/name/cholesterol/PNG";document.getElementById("url").innerHTML = url; document.getElementById("image").src=url;
url:
image: