<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Document</title>
<style>
*{margin:0;padding: 0;}
#img{position: absolute;left:1100px; top:45%;}
</style>
</head>
<body>
<img src="jiangshi.gif" id="img">
</body>
</html>
<script>
var left = 1100;
var timer = setInterval(function(){
left-=2;
img.style.left = left+"px";
},30)
</script>