diff --git a/ahmet/1.jpg b/ahmet/1.jpg
new file mode 100644
index 0000000..daa914c
Binary files /dev/null and b/ahmet/1.jpg differ
diff --git a/index.html b/index.html
index 08f7b23..c166455 100644
--- a/index.html
+++ b/index.html
@@ -15,6 +15,7 @@
+
+
+
diff --git a/js/gallery.js b/js/gallery.js
index 7103f0c..8f71ada 100644
--- a/js/gallery.js
+++ b/js/gallery.js
@@ -1,27 +1,29 @@
document.addEventListener('DOMContentLoaded', () => {
- const galleryContainer = document.getElementById('gallery-container');
- const totalImages = 50; // number of images you want to load
+ // Function to load images into a specific container from a specific folder
+ const loadGallery = (containerId, folderName, totalImages) => {
+ const container = document.getElementById(containerId);
+ if (!container) return;
- for (let i = 1; i <= totalImages; i++) {
- const img = document.createElement('img');
- img.alt = `Image ${i}`;
-
- // Try jpg first
- img.src = `gallery/${i}.jpg`;
-
- // fallback to png
- img.onerror = () => {
- img.src = `gallery/${i}.png`;
-
- // fallback to gif
+ for (let i = 1; i <= totalImages; i++) {
+ const img = document.createElement('img');
+ img.alt = `${folderName} Image ${i}`;
+
+ // Try loading jpg -> png -> gif
+ img.src = `${folderName}/${i}.jpg`;
img.onerror = () => {
- img.src = `gallery/${i}.gif`;
-
- // hide if all fail
- img.onerror = () => { img.style.display = 'none'; };
+ img.src = `${folderName}/${i}.png`;
+ img.onerror = () => {
+ img.src = `${folderName}/${i}.gif`;
+ img.onerror = () => { img.style.display = 'none'; };
+ };
};
- };
+ container.appendChild(img);
+ }
+ };
- galleryContainer.appendChild(img);
- }
-});
+ // Load your original Gallery
+ loadGallery('gallery-container', 'gallery', 50);
+
+ // Load your new Ahmet Museum (adjust the number 20 to however many photos you have)
+ loadGallery('ahmet-container', 'ahmet', 20);
+});
\ No newline at end of file