That will result in NaN, i.e. not a number. Kill the 'px'.
document.img1.style.left = parseInt(document.img1.style.left) + 20 + "px";
This assumes that style.left is set, and not empty. If it's empty, it will fail, and you'll need a condition that checks this (and uses 0 for the calculation if so) or gets the left some other way, e.g. .offsetLeft).