function next(){ var box=document.getElementById('carusel'); var leftnow = Number(box.style.left.replace('px','')); box.style.left = leftnow+100+"px"; };