How to change the src attribute of a HTMLImageElement in JavaScript?
src
HTMLImageElement
I need help to convert logo.attr(\'src\',\'img/rm2.png\')
logo.attr(\'src\',\'img/rm2.png\')
Since you say you want to do this in different places of the program, I would create a function like this:
function ChangeImage(image_id,path) { document.images[image_id].src = path }