Little mysterious script here
- Code: Select all
el.innerHTML.thisImage = 'images/add.png';
innerHTML will return the
HTML contents of an element (a string), so adding .thisImage to a string will return nothing. You want something like this:
- Code: Select all
document.getElementById('image_id').src = 'mysrc.gif';