The idea is that there will be a background image of a `
` that changes every 5 seconds.
Currently, I have an image of width: 1600px that changes every 5 seconds, however when the window is too small, it creates scrollbars as it is not truly a background. I want to have the image as a background, centered, so any excess on the right and left will be left offscreen with no scroll bars.
This reply has been reported for inappropriate content.
rather than a div containing an image how about setting the background with css then centring it with the position parameter’s with no set width your issue with scroll bars should disappear until it hits actual content.
As for changing it every five seconds take a look at jquery setTimeout function