This is a simple web application that rotates through a set of images stored in a folder. The app is built using HTML, CSS, and JavaScript.
- Automatically rotates images every 3 seconds.
- Simple and clean design.
- Easy to add more images.
/DRIP /images image1.jpg image2.jpg image3.jpg // Add more images here index.html styles.css script.js
-
Clone the repository:
git clone https://github.com/gogorichie/image-rotator.git cd image-rotator
-
Add your images: Place your images in the
images
folder. Make sure to update the file names in thescript.js
file if you add or change images. -
Update the image paths: Open
script.js
and add the paths of your images to theimages
array:const images = [ 'images/image1.jpg', 'images/image2.jpg', 'images/image3.jpg', // Add more image paths as needed ];
-
Open the app: Open
index.html
in your web browser to see the image rotator in action.
-
Change rotation interval: To change the time interval for image rotation, modify the
setInterval
function inscript.js
:setInterval(rotateImage, 3000); // Change image every 3 seconds
The interval is set in milliseconds (3000ms = 3 seconds).
-
Adjust styling: To change the appearance of the app, update
styles.css
with your desired
This project is licensed under the MIT License. See the LICENSE file for details.
Contributions are welcome! Please feel free to submit a pull request or open an issue to improve the project.
Created by Richard Lewis - feel free to contact me!