I am making a website for a friend and he ask me to do a similar website like this http://www.santalibrada.com.py/
I have an image that is 10000px x 1080px and I want to make a slideshow using only that image.
I want to make a button that moves the image to the right 1920px, I try this way
<script>
function slide() {
var slideImage = document.getElementById('image');
slideImage.style.position = "absolute"
slideImage.style.transform = "translateX(-1920px)"
}
</script>
But it only moves once. How can I make it so when I press the button again it goes another 1920px to the right?
I will add an image so you guys can understand better because my english is not that good.