Delete BloomValleyNursery_FullProjectFiles directory
|
@ -1,275 +0,0 @@
|
||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta charset="UTF-8" />
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<meta
|
|
||||||
name="description"
|
|
||||||
content="Bloom Valley Nursery offers a variety of plants, garden tools, and expert gardening advice for your home and garden."
|
|
||||||
/>
|
|
||||||
<script
|
|
||||||
src="https://kit.fontawesome.com/acb7c3b0da.js"
|
|
||||||
crossorigin="anonymous"
|
|
||||||
></script>
|
|
||||||
<title>About Us - Bloom Valley Nursery</title>
|
|
||||||
<link rel="stylesheet" href="styles.css" />
|
|
||||||
</head>
|
|
||||||
<body id="about-page">
|
|
||||||
<!-- Header Section -->
|
|
||||||
<header role="banner">
|
|
||||||
<div class="logo">
|
|
||||||
<img
|
|
||||||
src="images/Client1_LogoPalette2_F0C06D.png"
|
|
||||||
alt="Bloom Valley Nursery Logo"/>
|
|
||||||
</div>
|
|
||||||
<h1>Bloom Valley Nursery</h1>
|
|
||||||
<!-- Navigation Bar -->
|
|
||||||
<nav role="navigation" aria-label="Main Navigation">
|
|
||||||
<ul>
|
|
||||||
<li>
|
|
||||||
<a href="index.html">Home</a></li>
|
|
||||||
<li><a href="gallery.html">Gallery</a></li>
|
|
||||||
<li><a href="about.html" aria-current="page" class="current-page">About Us</a></li>
|
|
||||||
<li><a href="community.html">Community Events</a></li>
|
|
||||||
</ul>
|
|
||||||
<div>
|
|
||||||
<button
|
|
||||||
id="shopping-cart"
|
|
||||||
aria-label="Open shopping cart"
|
|
||||||
class="fa-solid fa-cart-shopping fa-2xl">
|
|
||||||
</button>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
</header>
|
|
||||||
|
|
||||||
<!-- Main Content Section -->
|
|
||||||
<main role="main" id="main-about">
|
|
||||||
<div id="main-top">
|
|
||||||
<aside
|
|
||||||
id="business-info"
|
|
||||||
aria-label="Hours of operation and contact info"
|
|
||||||
>
|
|
||||||
<h3>Contact Us</h3>
|
|
||||||
<div id="phone">
|
|
||||||
<h4><strong>Phone:</strong></h4>
|
|
||||||
<p>(555) 123-4567</p>
|
|
||||||
</div>
|
|
||||||
<h3>Hours of Operation</h3>
|
|
||||||
<div id="hours">
|
|
||||||
<h4><strong>Monday - Friday:</strong></h4>
|
|
||||||
<p>9:00 AM - 6:00 PM</p>
|
|
||||||
<h4><strong>Saturday & Sunday:</strong></h4>
|
|
||||||
<p>10:00 AM - 5:00 PM</p>
|
|
||||||
</div>
|
|
||||||
</aside>
|
|
||||||
<div id="story" aria-label="History of Bloom Valley Nursery">
|
|
||||||
<h1>The Story of Bloom Valley</h1>
|
|
||||||
<p>
|
|
||||||
Legend has it that in 1822, Benjamin Bloom, his wife Violet, and
|
|
||||||
their young daughter Nora stumbled upon a breathtaking valley
|
|
||||||
brimming with vibrant, rare flowers during their journey westward.
|
|
||||||
Enchanted by its beauty, they decided to settle there, abandoning
|
|
||||||
their plans to reach California. This picturesque haven became known
|
|
||||||
as Bloom Valley.
|
|
||||||
</p>
|
|
||||||
<p>
|
|
||||||
Today, on the very land where the Bloom family found their paradise,
|
|
||||||
stands Bloom Valley Nursery. Still family-owned and operated,
|
|
||||||
siblings Bethany, Vincent, and Nathaniel Bloom carry forward a
|
|
||||||
legacy of preserving and sharing the natural beauty that captivated
|
|
||||||
the hearts of their ancestors over two centuries ago.
|
|
||||||
</p>
|
|
||||||
<p>Though many things have changed through the years, our commitment to serving our community has remained the same. Let us help you cultivate joy, one bloom at a time!</p>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div id="main-bottom">
|
|
||||||
<div id="feedback" aria-label="Feedback form">
|
|
||||||
<div id="feedback-intro">
|
|
||||||
<h1>We Want to Hear From You!</h1>
|
|
||||||
<h3>Your feedback provides us with valuable insight into where we stand in our commitment to our neighbors, friends, and the entire Bloom Valley community.</h3>
|
|
||||||
<p>Feel free to contact us by filling out the form below if you have any questions, concerns, or simply want to tell us how we can better serve you in the future. You are also welcome to give us a call at the number above if you need to speak with someone directly. Our friendly staff can help answer your questions or guide you in placing custom orders as well!</p>
|
|
||||||
</div>
|
|
||||||
<div id="feedback-form">
|
|
||||||
<form action="#" method="POST">
|
|
||||||
<div id="customer-info">
|
|
||||||
<div id="name-field">
|
|
||||||
<label for="name">Name:</label>
|
|
||||||
<input
|
|
||||||
type="text"
|
|
||||||
id="name"
|
|
||||||
name="name"
|
|
||||||
aria-label="Enter your name here" placeholder="Your Name"
|
|
||||||
required/>
|
|
||||||
</div>
|
|
||||||
<div id="phone-field">
|
|
||||||
<label for="tel">Phone Number:</label>
|
|
||||||
<input
|
|
||||||
type="tel"
|
|
||||||
id="tel"
|
|
||||||
name="telephone"
|
|
||||||
aria-label="Enter your contact phone number here" placeholder="Your Phone Number"
|
|
||||||
required/>
|
|
||||||
</div>
|
|
||||||
<div id="email-field">
|
|
||||||
<label for="email">Email:</label>
|
|
||||||
<input
|
|
||||||
type="email"
|
|
||||||
id="email"
|
|
||||||
name="email"
|
|
||||||
aria-label="Enter your contact email here" placeholder="user@domain.com"
|
|
||||||
required/>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div id="customer-message">
|
|
||||||
<div id="message-field">
|
|
||||||
<label for="message">Message:</label>
|
|
||||||
<textarea
|
|
||||||
id="message"
|
|
||||||
name="message"
|
|
||||||
rows="5"
|
|
||||||
aria-label="Enter feedback or inquiries here" placeholder="Enter feedback or inquiries here..."
|
|
||||||
required>
|
|
||||||
</textarea>
|
|
||||||
</div>
|
|
||||||
<div id="form-submit-btn">
|
|
||||||
<button
|
|
||||||
id="form-submit"
|
|
||||||
type="submit"
|
|
||||||
aria-label="Submit feedback or inquiry"
|
|
||||||
>Submit
|
|
||||||
</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</main>
|
|
||||||
|
|
||||||
<!-- Footer Section -->
|
|
||||||
<footer role="contentinfo">
|
|
||||||
<div id="newsletter-container">
|
|
||||||
<label for="email-input" class="hidden">Enter your email to subscribe to our newsletter</label>
|
|
||||||
<form id="newsletter-form">
|
|
||||||
<input
|
|
||||||
type="email"
|
|
||||||
id="email-input"
|
|
||||||
aria-label="Enter your email to Subscribe"
|
|
||||||
placeholder="Subscribe@BloomValleyNursery.com"
|
|
||||||
/>
|
|
||||||
<button id="submit-btn" type="submit" aria-label="Submit the subscribe form">
|
|
||||||
Subscribe Now!
|
|
||||||
</button>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
<div id="footer-nav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="index.html">Home</a></li>
|
|
||||||
<li><a href="gallery.html">Gallery</a></li>
|
|
||||||
<li><a href="about.html" class="current-page">About Us</a></li>
|
|
||||||
<li><a href="community.html">Community Events</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
<div id="social-media">
|
|
||||||
<p>Check us out on social media!</p>
|
|
||||||
<ul class="social-icons">
|
|
||||||
<li id="pinterest">
|
|
||||||
<a href="#" aria-label="Follow us on Pinterest"
|
|
||||||
><i class="fa-brands fa-square-pinterest fa-lg"></i></a></li>
|
|
||||||
<li id="facebook">
|
|
||||||
<a href="#" aria-label="Follow us on Facebook"
|
|
||||||
><i class="fa-brands fa-facebook fa-lg"></i
|
|
||||||
></a>
|
|
||||||
</li>
|
|
||||||
<li id="instagram">
|
|
||||||
<a href="#" aria-label="Follow us on Instagram"
|
|
||||||
><i class="fa-brands fa-instagram fa-lg"></i
|
|
||||||
></a>
|
|
||||||
</li>
|
|
||||||
<li id="twitter">
|
|
||||||
<a href="#" aria-label="Follow us on X (Twitter)"
|
|
||||||
><i class="fa-brands fa-square-x-twitter fa-lg"></i
|
|
||||||
></a>
|
|
||||||
</li>
|
|
||||||
<li id="youtube">
|
|
||||||
<a href="#" aria-label="View our Youtube channel"
|
|
||||||
><i class="fa-brands fa-youtube fa-lg"></i
|
|
||||||
></a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
<div id="copyright">© 2024 Bloom Valley Nursery</div>
|
|
||||||
</footer>
|
|
||||||
<!-- Custom Modal for Newsletter Subscription -->
|
|
||||||
<div id="newsletter-modal" class="modal">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal" id="newsletter-close-btn">×</span>
|
|
||||||
<h2>Newsletter Subscription</h2>
|
|
||||||
<form id="newsletter-form">
|
|
||||||
<input
|
|
||||||
type="email"
|
|
||||||
id="email-input"
|
|
||||||
placeholder="Enter your email"
|
|
||||||
required
|
|
||||||
aria-label="Enter your email to subscribe"
|
|
||||||
/>
|
|
||||||
<button type="submit" id="subscribe-btn">Subscribe</button>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Custom Alert Modal -->
|
|
||||||
<div id="custom-alert" class="modal hidden">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal" id="alert-close-btn">×</span>
|
|
||||||
<p id="alert-message"></p>
|
|
||||||
<button id="alert-ok-button">OK</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Modal for Shopping Cart -->
|
|
||||||
<div id="cart-modal" class="modal" style="display: none;">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal">×</span>
|
|
||||||
<h2>Your Shopping Cart</h2>
|
|
||||||
<ul id="cart-items"></ul> <!-- Dynamically populated -->
|
|
||||||
<p id="cart-total"></p> <!-- Sub-total will appear here -->
|
|
||||||
<div class="modal-buttons">
|
|
||||||
<button id="clear-cart-modal-btn">Clear Cart</button>
|
|
||||||
<button id="process-order-modal-btn">Process Order</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Modal for Item Added -->
|
|
||||||
<div id="item-added-modal" class="modal" style="display: none;">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal" id="item-added-close">×</span>
|
|
||||||
<p id="item-added-message"></p> <!-- Dynamically set message -->
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Confirmation Modal -->
|
|
||||||
<div id="confirmation-modal" class="modal" style="display: none;">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal" id="confirmation-close-btn">×</span>
|
|
||||||
<p id="confirmation-message"></p> <!-- Dynamic confirmation message -->
|
|
||||||
<button id="confirmation-confirm-btn">Confirm</button>
|
|
||||||
<button id="confirmation-close-btn">Close</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Final Confirmation Modal -->
|
|
||||||
<div id="final-confirmation-modal" class="modal" style="display: none;">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal" id="final-confirmation-close-btn">×</span>
|
|
||||||
<p id="final-confirmation-message"></p> <!-- Message after successful action -->
|
|
||||||
<button id="final-confirmation-close-btn">Close</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- This loads after the page is read by browser -->
|
|
||||||
<script src="cart.js"></script>
|
|
||||||
<script src="newsletter.js"></script>
|
|
||||||
<script src="feedback.js"></script>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,178 +0,0 @@
|
||||||
document.addEventListener('DOMContentLoaded', () => {
|
|
||||||
let cart = JSON.parse(sessionStorage.getItem('cart')) || [];
|
|
||||||
|
|
||||||
// Get modal and cart-related elements
|
|
||||||
const modal = document.getElementById('cart-modal');
|
|
||||||
const closeModal = document.querySelector('.close-modal');
|
|
||||||
const cartItemsContainer = document.getElementById('cart-items');
|
|
||||||
const cartTotalContainer = document.getElementById('cart-total');
|
|
||||||
const clearCartModalButton = document.getElementById('clear-cart-modal-btn');
|
|
||||||
const processOrderModalButton = document.getElementById('process-order-modal-btn');
|
|
||||||
|
|
||||||
// Custom confirmation modals for clear cart and process order
|
|
||||||
const confirmationModal = document.getElementById('confirmation-modal');
|
|
||||||
const confirmationMessage = document.getElementById('confirmation-message');
|
|
||||||
const confirmationCloseButton = document.getElementById('confirmation-close-btn');
|
|
||||||
const confirmationConfirmButton = document.getElementById('confirmation-confirm-btn');
|
|
||||||
|
|
||||||
// Buttons
|
|
||||||
const shoppingCartButton = document.getElementById('shopping-cart');
|
|
||||||
const cartDetailsButton = document.getElementById('cart-details');
|
|
||||||
|
|
||||||
// Custom alert modal for item added
|
|
||||||
const itemAddedModal = document.getElementById('item-added-modal');
|
|
||||||
const itemAddedMessage = document.getElementById('item-added-message');
|
|
||||||
const itemAddedClose = document.getElementById('item-added-close');
|
|
||||||
|
|
||||||
// Final confirmation modal for success messages
|
|
||||||
const finalConfirmationModal = document.getElementById('final-confirmation-modal');
|
|
||||||
const finalConfirmationMessage = document.getElementById('final-confirmation-message');
|
|
||||||
const finalConfirmationCloseButton = document.getElementById('final-confirmation-close-btn');
|
|
||||||
|
|
||||||
// Function to render the cart
|
|
||||||
function renderCart() {
|
|
||||||
cart = JSON.parse(sessionStorage.getItem('cart')) || [];
|
|
||||||
cartItemsContainer.innerHTML = ''; // Clear existing items
|
|
||||||
let total = 0;
|
|
||||||
|
|
||||||
if (cart.length === 0) {
|
|
||||||
cartItemsContainer.innerHTML = '<li>Your cart is empty.</li>';
|
|
||||||
cartTotalContainer.textContent = '';
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
cart.forEach(item => {
|
|
||||||
const itemTotal = item.price * item.quantity;
|
|
||||||
total += itemTotal;
|
|
||||||
|
|
||||||
const listItem = document.createElement('li');
|
|
||||||
listItem.textContent = `${item.name} x ${item.quantity} - $${itemTotal.toFixed(2)}`;
|
|
||||||
cartItemsContainer.appendChild(listItem);
|
|
||||||
});
|
|
||||||
|
|
||||||
cartTotalContainer.textContent = `Subtotal: $${total.toFixed(2)}`;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Show cart modal with current cart content
|
|
||||||
function showModal() {
|
|
||||||
renderCart(); // Always render the latest cart
|
|
||||||
modal.style.display = 'flex'; // Show the cart modal
|
|
||||||
}
|
|
||||||
|
|
||||||
// Show confirmation modal for actions (clear or process order)
|
|
||||||
function showConfirmationModal(message, action) {
|
|
||||||
confirmationMessage.textContent = message;
|
|
||||||
confirmationModal.style.display = 'flex'; // Show the confirmation modal
|
|
||||||
|
|
||||||
// Confirm action on the "Confirm" button
|
|
||||||
confirmationConfirmButton.onclick = () => {
|
|
||||||
action(); // Execute the passed action (clear cart, process order)
|
|
||||||
confirmationModal.style.display = 'none'; // Close the confirmation modal after confirming
|
|
||||||
};
|
|
||||||
|
|
||||||
// Close confirmation modal without performing any action
|
|
||||||
confirmationCloseButton.onclick = () => {
|
|
||||||
confirmationModal.style.display = 'none';
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
// Show final confirmation modal with success message
|
|
||||||
function showFinalConfirmationModal(message) {
|
|
||||||
finalConfirmationMessage.textContent = message;
|
|
||||||
finalConfirmationModal.style.display = 'flex'; // Show the final confirmation modal
|
|
||||||
finalConfirmationCloseButton.onclick = () => {
|
|
||||||
finalConfirmationModal.style.display = 'none'; // Close final confirmation modal
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
// Show custom modal when item is added to cart
|
|
||||||
function showItemAddedModal(message) {
|
|
||||||
itemAddedMessage.textContent = message; // Set message dynamically
|
|
||||||
itemAddedModal.style.display = 'flex'; // Show the modal
|
|
||||||
itemAddedClose.addEventListener('click', () => {
|
|
||||||
itemAddedModal.style.display = 'none'; // Close the modal
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
// Attach event listeners to both cart buttons
|
|
||||||
[shoppingCartButton, cartDetailsButton].forEach(button => {
|
|
||||||
if (button) {
|
|
||||||
button.addEventListener('click', showModal); // Open modal when clicked
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
// Close modal when clicking outside of it
|
|
||||||
window.addEventListener('click', event => {
|
|
||||||
if (event.target === modal) {
|
|
||||||
modal.style.display = 'none';
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
// Close the modal by clicking the close button (for cart modal)
|
|
||||||
if (closeModal) {
|
|
||||||
closeModal.addEventListener('click', () => {
|
|
||||||
modal.style.display = 'none';
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
// Add to cart functionality
|
|
||||||
const addToCartButtons = document.querySelectorAll('.add-to-cart-btn');
|
|
||||||
addToCartButtons.forEach(button => {
|
|
||||||
button.addEventListener('click', () => {
|
|
||||||
const productId = parseInt(button.dataset.productId, 10);
|
|
||||||
const product = products.find(item => item.id === productId);
|
|
||||||
|
|
||||||
if (product) {
|
|
||||||
const existingProduct = cart.find(item => item.id === productId);
|
|
||||||
|
|
||||||
if (existingProduct) {
|
|
||||||
existingProduct.quantity++;
|
|
||||||
} else {
|
|
||||||
cart.push({ ...product, quantity: 1 });
|
|
||||||
}
|
|
||||||
|
|
||||||
sessionStorage.setItem('cart', JSON.stringify(cart)); // Save cart to session storage
|
|
||||||
showItemAddedModal(`${product.name} has been added to the cart!`); // Show custom modal
|
|
||||||
}
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
// Event listener for Clear Cart button in the modal
|
|
||||||
if (clearCartModalButton) {
|
|
||||||
clearCartModalButton.addEventListener('click', () => {
|
|
||||||
showConfirmationModal('Are you sure you want to clear the cart?', () => {
|
|
||||||
sessionStorage.removeItem('cart');
|
|
||||||
cart = [];
|
|
||||||
renderCart(); // Re-render cart after clearing it
|
|
||||||
showFinalConfirmationModal('Cart has been cleared!'); // Show final confirmation for cart clearing
|
|
||||||
});
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
// Event listener for Process Order button in the modal
|
|
||||||
if (processOrderModalButton) {
|
|
||||||
processOrderModalButton.addEventListener('click', () => {
|
|
||||||
if (cart.length === 0) {
|
|
||||||
showItemAddedModal('Your cart is empty. Please add items to the cart before processing the order.');
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
showConfirmationModal('Are you sure you want to process your order?', () => {
|
|
||||||
const receiptNumber = Math.floor(Math.random() * 1000000); // Generate receipt number
|
|
||||||
showFinalConfirmationModal(`Thank you for your order!\nYour receipt number is ${receiptNumber}.`);
|
|
||||||
sessionStorage.removeItem('cart');
|
|
||||||
cart = [];
|
|
||||||
renderCart(); // Re-render cart after processing the order
|
|
||||||
});
|
|
||||||
});
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
const allCloseButtons = document.querySelectorAll('.close-modal');
|
|
||||||
allCloseButtons.forEach(button => {
|
|
||||||
button.addEventListener('click', () => {
|
|
||||||
// Close the parent modal of the button clicked
|
|
||||||
const modal = button.closest('.modal');
|
|
||||||
modal.style.display = 'none';
|
|
||||||
});
|
|
||||||
});
|
|
|
@ -1,256 +0,0 @@
|
||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta charset="UTF-8" />
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<meta
|
|
||||||
name="description"
|
|
||||||
content="Bloom Valley Nursery offers a variety of plants, garden tools, and expert gardening advice for your home and garden."
|
|
||||||
/>
|
|
||||||
<script
|
|
||||||
src="https://kit.fontawesome.com/acb7c3b0da.js"
|
|
||||||
crossorigin="anonymous"
|
|
||||||
></script>
|
|
||||||
<title>Community Events - Bloom Valley Nursery</title>
|
|
||||||
<link rel="stylesheet" href="styles.css" />
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<!-- Header Section -->
|
|
||||||
<header role="banner">
|
|
||||||
<div class="logo">
|
|
||||||
<img
|
|
||||||
src="images/Client1_LogoPalette2_F0C06D.png"
|
|
||||||
alt="Bloom Valley Nursery Logo"
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
<h1>Bloom Valley Nursery</h1>
|
|
||||||
<!-- Navigation Bar -->
|
|
||||||
<nav role="navigation" aria-label="Main Navigation">
|
|
||||||
<ul>
|
|
||||||
<li><a href="index.html">Home</a></li>
|
|
||||||
<li><a href="gallery.html">Gallery</a></li>
|
|
||||||
<li><a href="about.html">About Us</a></li>
|
|
||||||
<li><a href="community.html" aria-current="page" class="current-page">Community Events</a></li>
|
|
||||||
</ul>
|
|
||||||
<button
|
|
||||||
id="shopping-cart"
|
|
||||||
aria-label="Open shopping cart"
|
|
||||||
class="fa-solid fa-cart-shopping fa-2xl"
|
|
||||||
></button>
|
|
||||||
</nav>
|
|
||||||
</header>
|
|
||||||
|
|
||||||
<!-- Main Content Section -->
|
|
||||||
<main role="main" id="community-page">
|
|
||||||
<h1>Mark Your Calendars!</h1>
|
|
||||||
<div id="calendar-events-container">
|
|
||||||
<div class="calendar">
|
|
||||||
<iframe
|
|
||||||
src="https://calendar.google.com/calendar/embed?src=your_calendar_id&ctz=America/Chicago"
|
|
||||||
style="border: 0; width: 90vww; height: 600px"
|
|
||||||
frameborder="0"
|
|
||||||
scrolling="no" aria-label="Google Calendar displaying upcoming events at Bloom Valley Nursery">
|
|
||||||
</iframe><!-- change "your_calendar_id" to an actual Google Calendar ID (Not possible due to the Client Scenario being fictional. This would require creating a fake Google account.)-->
|
|
||||||
</div>
|
|
||||||
<section class="events" aria-label="List of upcoming local events">
|
|
||||||
<h2>Upcoming Events</h2>
|
|
||||||
<div class="event-list">
|
|
||||||
<div id="bvn-events">
|
|
||||||
<h3>Events at Bloom Valley Nursery</h3>
|
|
||||||
<p>
|
|
||||||
All workshops at Bloom Valley Nursery are provided free of charge to
|
|
||||||
anyone interested in learning techniques and ideas for creating a
|
|
||||||
visually appealing living space that can be personalized to suite
|
|
||||||
individual needs. Registration links are provided in each Google
|
|
||||||
Calendar Event by clicking on the date of the event within the
|
|
||||||
Google Calendar on this page.
|
|
||||||
</p>
|
|
||||||
<ul>
|
|
||||||
<li>
|
|
||||||
<strong>Gardening and Landscaping 101:</strong><br><strong>When:</strong><br> 2nd Tuesday of
|
|
||||||
Every Month @ 6:30 pm.<br>Join Bethany Bloom as she shares her tips for
|
|
||||||
creating a themed decor through-out the home that you will be
|
|
||||||
delighted to share with your holiday guests.
|
|
||||||
</li>
|
|
||||||
<li>
|
|
||||||
<strong>Deck the Halls</strong><br><strong>When:</strong> Saturday @ 10:00 am.<br>Join
|
|
||||||
Nathaniel and Vincent as they guide us through picking and tending
|
|
||||||
the perfect live Christmas tree for your Christmas decoration
|
|
||||||
focal-point.
|
|
||||||
</li>
|
|
||||||
<li>
|
|
||||||
<strong>Christmas Eve and Christmas Day</strong><br><strong>Bloom Valley
|
|
||||||
Nursery will close on Christmas Eve at 8:00 pm</strong> for any last-minute
|
|
||||||
shopping.<br>The nursery will remain <strong>closed until January 2nd</strong>. During
|
|
||||||
this time, we will be making improvements to the nursery grounds and
|
|
||||||
store with the aim of better serving our Bloom Valley neighbors,
|
|
||||||
friends and family. We are excited to share the new features and changes with
|
|
||||||
you in the New Year!<br><strong>Happy Holidays!!!</strong>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
<div id="community-wide">
|
|
||||||
<h3>Community-Wide Events</h3>
|
|
||||||
<p>
|
|
||||||
This section includes local community events for which Bloom Valley
|
|
||||||
Nursery is in partner with or a sponsor of. These events are
|
|
||||||
typically free of charge, but can include sub-events by other local
|
|
||||||
organizations and businesses that may not be free of charge. Check
|
|
||||||
with specific organizations, businesses, and the Bloom Valley
|
|
||||||
Chamber of Commerce for specific details that may not be provided by
|
|
||||||
Bloom Valley Nursery.
|
|
||||||
</p>
|
|
||||||
<ul>
|
|
||||||
<li>
|
|
||||||
<strong>Tree Lighting Ceremony</strong><br><strong>When:</strong></br>Thursday @ 6:00 pm.<br>
|
|
||||||
Help us kick off the Holiday festivities by joining the Bloom
|
|
||||||
family, along with the Bloom Valley Chamber of Commerce, the Bloom
|
|
||||||
Valley Garden Club, and many other local businesses and
|
|
||||||
organizations, as we gather <strong>in front of City Hall</strong> for the annual Tree
|
|
||||||
Lighting Ceremony! This event will include performances by the Bloom
|
|
||||||
Valley Junior and Senior High Marching Bands, a workshop for making
|
|
||||||
tree ornaments, the annual Chili Cook-off, and much more!
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
<!-- Add more events as needed -->
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<p>
|
|
||||||
For more details, to add events to this page, or to leave feedback,
|
|
||||||
<a
|
|
||||||
href="about.html#feedback"
|
|
||||||
aria-label="Go to the feedback form on the About Us page to leave feedback or inquiries."
|
|
||||||
>click here</a
|
|
||||||
> to send us a message.
|
|
||||||
</p>
|
|
||||||
</main>
|
|
||||||
|
|
||||||
<!-- Footer Section -->
|
|
||||||
<footer role="contentinfo">
|
|
||||||
<div id="newsletter-container">
|
|
||||||
<label for="email-input" class="hidden">Enter your email to subscribe to our newsletter</label>
|
|
||||||
<form id="newsletter-form">
|
|
||||||
<input
|
|
||||||
type="email"
|
|
||||||
id="email-input"
|
|
||||||
aria-label="Enter your email to Subscribe"
|
|
||||||
placeholder="Subscribe@BloomValleyNursery.com"
|
|
||||||
/>
|
|
||||||
<button id="submit-btn" type="submit" aria-label="Submit the subscribe form">
|
|
||||||
Subscribe Now!
|
|
||||||
</button>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
<div id="footer-nav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="index.html">Home</a></li>
|
|
||||||
<li><a href="gallery.html">Gallery</a></li>
|
|
||||||
<li><a href="about.html">About Us</a></li>
|
|
||||||
<li><a href="community.html" class="current-page">Community Events</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
<div id="social-media">
|
|
||||||
<p>Check us out on social media!</p>
|
|
||||||
<ul class="social-icons">
|
|
||||||
<li id="pinterest">
|
|
||||||
<a href="#" aria-label="Follow us on Pinterest"
|
|
||||||
><i class="fa-brands fa-square-pinterest fa-lg"></i></a></li>
|
|
||||||
<li id="facebook">
|
|
||||||
<a href="#" aria-label="Follow us on Facebook"
|
|
||||||
><i class="fa-brands fa-facebook fa-lg"></i
|
|
||||||
></a>
|
|
||||||
</li>
|
|
||||||
<li id="instagram">
|
|
||||||
<a href="#" aria-label="Follow us on Instagram"
|
|
||||||
><i class="fa-brands fa-instagram fa-lg"></i
|
|
||||||
></a>
|
|
||||||
</li>
|
|
||||||
<li id="twitter">
|
|
||||||
<a href="#" aria-label="Follow us on X (Twitter)"
|
|
||||||
><i class="fa-brands fa-square-x-twitter fa-lg"></i
|
|
||||||
></a>
|
|
||||||
</li>
|
|
||||||
<li id="youtube">
|
|
||||||
<a href="#" aria-label="View our Youtube channel"
|
|
||||||
><i class="fa-brands fa-youtube fa-lg"></i
|
|
||||||
></a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
<div id="copyright">© 2024 Bloom Valley Nursery</div>
|
|
||||||
</footer>
|
|
||||||
<!-- Custom Modal for Newsletter Subscription -->
|
|
||||||
<div id="newsletter-modal" class="modal">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal" id="newsletter-close-btn">×</span>
|
|
||||||
<h2>Newsletter Subscription</h2>
|
|
||||||
<form id="newsletter-form">
|
|
||||||
<input
|
|
||||||
type="email"
|
|
||||||
id="email-input"
|
|
||||||
placeholder="Enter your email"
|
|
||||||
required
|
|
||||||
aria-label="Enter your email to subscribe"
|
|
||||||
/>
|
|
||||||
<button type="submit" id="subscribe-btn">Subscribe</button>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Custom Alert Modal -->
|
|
||||||
<div id="custom-alert" class="modal hidden">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal" id="alert-close-btn">×</span>
|
|
||||||
<p id="alert-message"></p>
|
|
||||||
<button id="alert-ok-button">OK</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Modal for Shopping Cart -->
|
|
||||||
<div id="cart-modal" class="modal" style="display: none;">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal">×</span>
|
|
||||||
<h2>Your Shopping Cart</h2>
|
|
||||||
<ul id="cart-items"></ul> <!-- Dynamically populated -->
|
|
||||||
<p id="cart-total"></p> <!-- Sub-total will appear here -->
|
|
||||||
<div class="modal-buttons">
|
|
||||||
<button id="clear-cart-modal-btn">Clear Cart</button>
|
|
||||||
<button id="process-order-modal-btn">Process Order</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Modal for Item Added -->
|
|
||||||
<div id="item-added-modal" class="modal" style="display: none;">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal" id="item-added-close">×</span>
|
|
||||||
<p id="item-added-message"></p> <!-- Dynamically set message -->
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Confirmation Modal -->
|
|
||||||
<div id="confirmation-modal" class="modal" style="display: none;">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal" id="confirmation-close-btn">×</span>
|
|
||||||
<p id="confirmation-message"></p> <!-- Dynamic confirmation message -->
|
|
||||||
<button id="confirmation-confirm-btn">Confirm</button>
|
|
||||||
<button id="confirmation-close-btn">Close</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Final Confirmation Modal -->
|
|
||||||
<div id="final-confirmation-modal" class="modal" style="display: none;">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal" id="final-confirmation-close-btn">×</span>
|
|
||||||
<p id="final-confirmation-message"></p> <!-- Message after successful action -->
|
|
||||||
<button id="final-confirmation-close-btn">Close</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- This loads after the page is read by browser -->
|
|
||||||
<script src="cart.js"></script>
|
|
||||||
<script src="newsletter.js"></script>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,93 +0,0 @@
|
||||||
document.addEventListener('DOMContentLoaded', () => {
|
|
||||||
const feedbackForm = document.querySelector('#feedback-form form');
|
|
||||||
const nameInput = document.getElementById('name');
|
|
||||||
const emailInput = document.getElementById('email');
|
|
||||||
const phoneInput = document.getElementById('tel');
|
|
||||||
const messageInput = document.getElementById('message');
|
|
||||||
|
|
||||||
const alertBox = document.getElementById('custom-alert');
|
|
||||||
const alertMessage = document.getElementById('alert-message');
|
|
||||||
const alertOkButton = document.getElementById('alert-ok-button');
|
|
||||||
const alertCloseButton = document.getElementById('alert-close-btn');
|
|
||||||
|
|
||||||
const emailRegex = /^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/; // Email validation regex
|
|
||||||
const phoneRegex = /^[0-9]{10,15}$/; // Phone validation regex (10-15 digits)
|
|
||||||
const nameRegex = /^[a-zA-Z\s]{2,}$/; // Name validation regex (at least 2 letters)
|
|
||||||
const sqlInjectionRegex = /[;'"\\]/; // Prevent SQL injection-like characters
|
|
||||||
|
|
||||||
// Form submission handler
|
|
||||||
feedbackForm.addEventListener('submit', (event) => {
|
|
||||||
event.preventDefault(); // Prevent form submission and page refresh
|
|
||||||
|
|
||||||
const name = nameInput.value.trim();
|
|
||||||
const email = emailInput.value.trim();
|
|
||||||
const phone = phoneInput.value.trim();
|
|
||||||
const message = messageInput.value.trim();
|
|
||||||
|
|
||||||
// Validate each field
|
|
||||||
if (!nameRegex.test(name)) {
|
|
||||||
showCustomAlert('Please enter a valid name (letters and spaces only).');
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!emailRegex.test(email)) {
|
|
||||||
showCustomAlert('Please enter a valid email address.');
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!phoneRegex.test(phone)) {
|
|
||||||
showCustomAlert('Please enter a valid phone number (10-15 digits).');
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (sqlInjectionRegex.test(message)) {
|
|
||||||
showCustomAlert('Your message contains invalid characters.');
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Save feedback to localStorage
|
|
||||||
const feedbackData = {
|
|
||||||
name,
|
|
||||||
email,
|
|
||||||
phone,
|
|
||||||
message,
|
|
||||||
timestamp: new Date().toISOString(),
|
|
||||||
};
|
|
||||||
|
|
||||||
// Retrieve existing feedback data or initialize an empty array
|
|
||||||
const feedbackList = JSON.parse(localStorage.getItem('feedbackList')) || [];
|
|
||||||
feedbackList.push(feedbackData); // Add new feedback to the list
|
|
||||||
localStorage.setItem('feedbackList', JSON.stringify(feedbackList)); // Save updated list to localStorage
|
|
||||||
console.log('Feedback saved to localStorage:', feedbackList);
|
|
||||||
|
|
||||||
// Show success message
|
|
||||||
showCustomAlert('Thank you for your feedback! We appreciate hearing from you.');
|
|
||||||
feedbackForm.reset(); // Clear the input fields after submission
|
|
||||||
});
|
|
||||||
|
|
||||||
// Function to show the custom alert modal
|
|
||||||
function showCustomAlert(message) {
|
|
||||||
alertMessage.textContent = message; // Set modal message
|
|
||||||
alertBox.classList.remove('hidden'); // Display the modal
|
|
||||||
alertBox.style.display = 'flex'; // Ensure the modal is visible
|
|
||||||
}
|
|
||||||
|
|
||||||
// Function to close the custom alert modal
|
|
||||||
function closeCustomAlert() {
|
|
||||||
alertBox.classList.add('hidden'); // Hide the modal
|
|
||||||
alertBox.style.display = 'none'; // Ensure it's hidden
|
|
||||||
}
|
|
||||||
|
|
||||||
// Close modal on "OK" button click
|
|
||||||
alertOkButton.addEventListener('click', closeCustomAlert);
|
|
||||||
|
|
||||||
// Close modal on "X" button click
|
|
||||||
alertCloseButton.addEventListener('click', closeCustomAlert);
|
|
||||||
|
|
||||||
// Close modal when clicking outside the modal content
|
|
||||||
window.addEventListener('click', (event) => {
|
|
||||||
if (event.target === alertBox) {
|
|
||||||
closeCustomAlert();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
});
|
|
|
@ -1,127 +0,0 @@
|
||||||
// Gallery Carousel .js
|
|
||||||
const products = {
|
|
||||||
trees: [
|
|
||||||
{ id: 1, name: "Maple Tree", description: "Beautiful maple tree.", price: 55.00, image: "images/trees/MapleTree.png" },
|
|
||||||
{ id: 2, name: "Birch Tree", description: "Sturdy birch tree.", price: 45.00, image: "images/trees/BirchTree.png" },
|
|
||||||
{ id: 3, name: "Apple Tree", description: "Fruitful apple tree.", price: 35.00, image: "images/trees/AppleTree.png" }
|
|
||||||
],
|
|
||||||
indoor: [
|
|
||||||
{ id: 4, name: "Aloe Plant", description: "Thrives with 6-8 hours of direct sunlight a day.", price: 15.00, image: "images/indoor/AloePlant.png" },
|
|
||||||
{ id: 5, name: "Spider Plant", description: "Low-maintenance and perfect for spaces with lots of natural light.", price: 12.50, image: "images/indoor/SpiderPlant.png" },
|
|
||||||
{ id: 6, name: "String-of-Pearls Plant", description: "Best placed in east-facing windows or on shaded patios and balconies.", price: 20.00, image: "images/indoor/StringofPearls.png" }
|
|
||||||
],
|
|
||||||
tools: [
|
|
||||||
{ id: 7, name: "Watering Can", description: "Galvanized aluminum watering can.", price: 15.00, image: "images/accessories/WateringCan.png" },
|
|
||||||
{ id: 8, name: "Potting Soil", description: "Premium-blend of nutrient-rich potting soil - 10 lb bag.", price: 8.00, image: "images/accessories/PottingSoil.png" },
|
|
||||||
{ id: 9, name: "Bird House", description: "Handmade wooden bird house for hanging or mounting.", price: 11.00, image: "images/accessories/BirdHouse.png" }
|
|
||||||
]
|
|
||||||
};
|
|
||||||
|
|
||||||
document.addEventListener('DOMContentLoaded', () => {
|
|
||||||
console.log("DOM fully loaded and parsed"); // Check if the DOM is ready
|
|
||||||
|
|
||||||
const productCarousel = document.getElementById('product-carousel');
|
|
||||||
const scrollLeftButton = document.getElementById('scroll-left');
|
|
||||||
const scrollRightButton = document.getElementById('scroll-right');
|
|
||||||
const categoryButtons = document.querySelectorAll('.cat-btn');
|
|
||||||
|
|
||||||
// Scroll button functionality
|
|
||||||
scrollLeftButton.addEventListener('click', () => {
|
|
||||||
productCarousel.scrollBy({ left: -300, behavior: 'smooth' });
|
|
||||||
});
|
|
||||||
|
|
||||||
scrollRightButton.addEventListener('click', () => {
|
|
||||||
productCarousel.scrollBy({ left: 300, behavior: 'smooth' });
|
|
||||||
});
|
|
||||||
|
|
||||||
// Map buttons to categories
|
|
||||||
categoryButtons.forEach(button => {
|
|
||||||
button.addEventListener('click', (event) => {
|
|
||||||
event.preventDefault(); // Prevent default navigation
|
|
||||||
const url = new URL(button.href); // Parse the URL
|
|
||||||
const category = url.searchParams.get('category'); // Get category from the query parameter
|
|
||||||
updateProductList(category); // Update the product list
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
// Load default category or the one from the current URL
|
|
||||||
const currentUrl = new URL(window.location.href);
|
|
||||||
const defaultCategory = currentUrl.searchParams.get('category') || 'trees';
|
|
||||||
updateProductList(defaultCategory);
|
|
||||||
});
|
|
||||||
|
|
||||||
function updateScrollButtons() {
|
|
||||||
const scrollLeftButton = document.getElementById('scroll-left');
|
|
||||||
const scrollRightButton = document.getElementById('scroll-right');
|
|
||||||
const productCarousel = document.getElementById('product-carousel');
|
|
||||||
|
|
||||||
scrollLeftButton.style.display = productCarousel.scrollLeft === 0 ? 'none' : 'block';
|
|
||||||
scrollRightButton.style.display =
|
|
||||||
productCarousel.scrollWidth - productCarousel.clientWidth === productCarousel.scrollLeft
|
|
||||||
? 'none'
|
|
||||||
: 'block';
|
|
||||||
}
|
|
||||||
|
|
||||||
function updateProductList(category) {
|
|
||||||
const productList = document.getElementById("product-list");
|
|
||||||
if (!productList) {
|
|
||||||
console.error("Element with ID 'product-list' not found in the DOM.");
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
productList.innerHTML = ""; // Clear existing products
|
|
||||||
console.log(`Updating product list for category: ${category}`); // Debugging line
|
|
||||||
|
|
||||||
const selectedProducts = products[category];
|
|
||||||
|
|
||||||
if (selectedProducts) {
|
|
||||||
selectedProducts.forEach(product => {
|
|
||||||
const productCard = document.createElement("div");
|
|
||||||
productCard.className = "product-card";
|
|
||||||
|
|
||||||
console.log(`Creating product card for: ${product.name}`); // Debugging line
|
|
||||||
|
|
||||||
productCard.innerHTML = `
|
|
||||||
<img src="${product.image}" alt="${product.name}">
|
|
||||||
<h3>${product.name}</h3>
|
|
||||||
<p>${product.description}</p>
|
|
||||||
<p>$${product.price}</p>
|
|
||||||
<button class="add-to-cart-btn" data-product-id="${product.id}">Add to Cart</button>
|
|
||||||
`;
|
|
||||||
productList.appendChild(productCard);
|
|
||||||
|
|
||||||
// Add event listener for "Add to Cart" button
|
|
||||||
const addToCartButton = productCard.querySelector('.add-to-cart-btn');
|
|
||||||
addToCartButton.addEventListener('click', () => {
|
|
||||||
addToCart(product.id);
|
|
||||||
});
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
console.error(`No products found for category: ${category}`);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
function addToCart(productId) {
|
|
||||||
const product = findProductById(productId);
|
|
||||||
if (product) {
|
|
||||||
let cart = JSON.parse(sessionStorage.getItem('cart')) || [];
|
|
||||||
const existingProduct = cart.find(item => item.id === productId);
|
|
||||||
|
|
||||||
if (existingProduct) {
|
|
||||||
existingProduct.quantity++;
|
|
||||||
} else {
|
|
||||||
cart.push({ ...product, quantity: 1 });
|
|
||||||
}
|
|
||||||
|
|
||||||
sessionStorage.setItem('cart', JSON.stringify(cart));
|
|
||||||
alert(`${product.name} has been added to your cart!`);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
function findProductById(productId) {
|
|
||||||
for (let category in products) {
|
|
||||||
const product = products[category].find(item => item.id === productId);
|
|
||||||
if (product) return product;
|
|
||||||
}
|
|
||||||
return null;
|
|
||||||
}
|
|
|
@ -1,219 +0,0 @@
|
||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta charset="UTF-8" />
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<meta
|
|
||||||
name="description"
|
|
||||||
content="Bloom Valley Nursery offers a variety of plants, garden tools, and expert gardening advice for your home and garden."
|
|
||||||
/>
|
|
||||||
<script
|
|
||||||
src="https://kit.fontawesome.com/acb7c3b0da.js"
|
|
||||||
crossorigin="anonymous"
|
|
||||||
></script>
|
|
||||||
<title>Gallery - Bloom Valley Nursery</title>
|
|
||||||
<link rel="stylesheet" href="styles.css" />
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<!-- Header Section -->
|
|
||||||
<header role="banner">
|
|
||||||
<div class="logo">
|
|
||||||
<img
|
|
||||||
src="images/Client1_LogoPalette2_F0C06D.png"
|
|
||||||
alt="Bloom Valley Nursery Logo"/>
|
|
||||||
</div>
|
|
||||||
<h1>Bloom Valley Nursery</h1>
|
|
||||||
<!-- Navigation Bar -->
|
|
||||||
<nav role="navigation" aria-label="Main Navigation">
|
|
||||||
<ul>
|
|
||||||
<li>
|
|
||||||
<a href="index.html">Home</a></li>
|
|
||||||
<li><a href="gallery.html" aria-current="page" class="current-page">Gallery</a></li>
|
|
||||||
<li><a href="about.html">About Us</a></li>
|
|
||||||
<li><a href="community.html">Community Events</a></li>
|
|
||||||
</ul>
|
|
||||||
<div>
|
|
||||||
<button
|
|
||||||
id="shopping-cart"
|
|
||||||
aria-label="Open shopping cart"
|
|
||||||
class="fa-solid fa-cart-shopping fa-2xl">
|
|
||||||
</button>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
</header>
|
|
||||||
|
|
||||||
<!-- Main Content Section -->
|
|
||||||
<main role="main" id="main-gallery">
|
|
||||||
<div id="gallery-top">
|
|
||||||
<section id="product-carousel-feature" aria-label="Interactive Carousel of Available Products by Category.">
|
|
||||||
<h2>Products by Category</h2>
|
|
||||||
<div id="product-category-card">
|
|
||||||
<button
|
|
||||||
id="scroll-left"
|
|
||||||
aria-label="Scroll products left"
|
|
||||||
aria-controls="product-carousel"
|
|
||||||
class="fa-solid fa-chevron-left"
|
|
||||||
>
|
|
||||||
</button>
|
|
||||||
<div id="product-carousel">
|
|
||||||
<div id="product-list"><!--Product Cards will be dynamically inserted here--></div>
|
|
||||||
</div>
|
|
||||||
<button
|
|
||||||
id="scroll-right"
|
|
||||||
aria-label="Scroll products right"
|
|
||||||
aria-controls="product-carousel"
|
|
||||||
class="fa-solid fa-chevron-right"
|
|
||||||
>
|
|
||||||
</button>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<aside id="right-aside">
|
|
||||||
<div id="category-nav-container" aria-label="Available Product Categories">
|
|
||||||
<h2>Shop by Category</h2>
|
|
||||||
<div class="categories">
|
|
||||||
<ul>
|
|
||||||
<li><a href="gallery.html?category=trees#" class="cat-btn">Trees</a></li>
|
|
||||||
<li><a href="gallery.html?category=trees#" class="cat-btn">Shrubs</a></li>
|
|
||||||
<li><a href="gallery.html?category=indoor#" class="cat-btn">Indoor</a></li>
|
|
||||||
<li><a href="gallery.html?category=indoor#" class="cat-btn">Patio</a></li>
|
|
||||||
<li><a href="gallery.html?category=tools#" class="cat-btn">Tools</a></li>
|
|
||||||
<li><a href="gallery.html?category=tools#" class="cat-btn">Accessories</a></li>
|
|
||||||
<li><a href="gallery.html?category=tools#" class="cat-btn">Landscaping</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</aside>
|
|
||||||
</div>
|
|
||||||
<div id="gallery-bottom">
|
|
||||||
<button id="cart-details">View Shopping Cart</button>
|
|
||||||
</div>
|
|
||||||
</main>
|
|
||||||
|
|
||||||
<!-- Footer Section -->
|
|
||||||
<footer role="contentinfo">
|
|
||||||
<div id="newsletter-container">
|
|
||||||
<label for="email-input" class="hidden">Enter your email to subscribe to our newsletter</label>
|
|
||||||
<form id="newsletter-form">
|
|
||||||
<input
|
|
||||||
type="email"
|
|
||||||
id="email-input"
|
|
||||||
aria-label="Enter your email to Subscribe"
|
|
||||||
placeholder="Subscribe@BloomValleyNursery.com"
|
|
||||||
/>
|
|
||||||
<button id="submit-btn" type="submit" aria-label="Submit the subscribe form">
|
|
||||||
Subscribe Now!
|
|
||||||
</button>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
<div id="footer-nav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="index.html">Home</a></li>
|
|
||||||
<li><a href="gallery.html" class="current-page">Gallery</a></li>
|
|
||||||
<li><a href="about.html">About Us</a></li>
|
|
||||||
<li><a href="community.html">Community Events</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
<div id="social-media">
|
|
||||||
<p>Check us out on social media!</p>
|
|
||||||
<ul class="social-icons">
|
|
||||||
<li id="pinterest">
|
|
||||||
<a href="#" aria-label="Follow us on Pinterest"
|
|
||||||
><i class="fa-brands fa-square-pinterest fa-lg"></i></a></li>
|
|
||||||
<li id="facebook">
|
|
||||||
<a href="#" aria-label="Follow us on Facebook"
|
|
||||||
><i class="fa-brands fa-facebook fa-lg"></i
|
|
||||||
></a>
|
|
||||||
</li>
|
|
||||||
<li id="instagram">
|
|
||||||
<a href="#" aria-label="Follow us on Instagram"
|
|
||||||
><i class="fa-brands fa-instagram fa-lg"></i
|
|
||||||
></a>
|
|
||||||
</li>
|
|
||||||
<li id="twitter">
|
|
||||||
<a href="#" aria-label="Follow us on X (Twitter)"
|
|
||||||
><i class="fa-brands fa-square-x-twitter fa-lg"></i
|
|
||||||
></a>
|
|
||||||
</li>
|
|
||||||
<li id="youtube">
|
|
||||||
<a href="#" aria-label="View our Youtube channel"
|
|
||||||
><i class="fa-brands fa-youtube fa-lg"></i
|
|
||||||
></a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
<div id="copyright">© 2024 Bloom Valley Nursery</div>
|
|
||||||
</footer>
|
|
||||||
<!-- Custom Modal for Newsletter Subscription -->
|
|
||||||
<div id="newsletter-modal" class="modal">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal" id="newsletter-close-btn">×</span>
|
|
||||||
<h2>Newsletter Subscription</h2>
|
|
||||||
<form id="newsletter-form">
|
|
||||||
<input
|
|
||||||
type="email"
|
|
||||||
id="email-input"
|
|
||||||
placeholder="Enter your email"
|
|
||||||
required
|
|
||||||
aria-label="Enter your email to subscribe"
|
|
||||||
/>
|
|
||||||
<button type="submit" id="subscribe-btn">Subscribe</button>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Custom Alert Modal -->
|
|
||||||
<div id="custom-alert" class="modal hidden">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal" id="alert-close-btn">×</span>
|
|
||||||
<p id="alert-message"></p>
|
|
||||||
<button id="alert-ok-button">OK</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Modal for Shopping Cart -->
|
|
||||||
<div id="cart-modal" class="modal" style="display: none;">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal">×</span>
|
|
||||||
<h2>Your Shopping Cart</h2>
|
|
||||||
<ul id="cart-items"></ul> <!-- Dynamically populated -->
|
|
||||||
<p id="cart-total"></p> <!-- Sub-total will appear here -->
|
|
||||||
<div class="modal-buttons">
|
|
||||||
<button id="clear-cart-modal-btn">Clear Cart</button>
|
|
||||||
<button id="process-order-modal-btn">Process Order</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Modal for Item Added -->
|
|
||||||
<div id="item-added-modal" class="modal" style="display: none;">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal" id="item-added-close">×</span>
|
|
||||||
<p id="item-added-message"></p> <!-- Dynamically set message -->
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Confirmation Modal -->
|
|
||||||
<div id="confirmation-modal" class="modal" style="display: none;">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal" id="confirmation-close-btn">×</span>
|
|
||||||
<p id="confirmation-message"></p> <!-- Dynamic confirmation message -->
|
|
||||||
<button id="confirmation-confirm-btn">Confirm</button>
|
|
||||||
<button id="confirmation-close-btn">Close</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Final Confirmation Modal -->
|
|
||||||
<div id="final-confirmation-modal" class="modal" style="display: none;">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal" id="final-confirmation-close-btn">×</span>
|
|
||||||
<p id="final-confirmation-message"></p> <!-- Message after successful action -->
|
|
||||||
<button id="final-confirmation-close-btn">Close</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- This loads after the page is read by browser -->
|
|
||||||
<script src="gallery-carousel.js"></script>
|
|
||||||
<script src="cart.js"></script>
|
|
||||||
<script src="newsletter.js"></script>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
Before Width: | Height: | Size: 38 KiB |
Before Width: | Height: | Size: 73 KiB |
Before Width: | Height: | Size: 75 KiB |
Before Width: | Height: | Size: 55 KiB |
Before Width: | Height: | Size: 38 KiB |
Before Width: | Height: | Size: 44 KiB |
Before Width: | Height: | Size: 50 KiB |
Before Width: | Height: | Size: 83 KiB |
Before Width: | Height: | Size: 91 KiB |
Before Width: | Height: | Size: 87 KiB |
|
@ -1,239 +0,0 @@
|
||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta charset="UTF-8" />
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<meta
|
|
||||||
name="description"
|
|
||||||
content="Bloom Valley Nursery offers a variety of plants, garden tools, and expert gardening advice for your home and garden."
|
|
||||||
/>
|
|
||||||
<script
|
|
||||||
src="https://kit.fontawesome.com/acb7c3b0da.js"
|
|
||||||
crossorigin="anonymous"
|
|
||||||
></script>
|
|
||||||
<title>Homepage - Bloom Valley Nursery</title>
|
|
||||||
<link rel="stylesheet" href="styles.css" />
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<!-- Header Section -->
|
|
||||||
<header role="banner">
|
|
||||||
<div class="logo">
|
|
||||||
<img
|
|
||||||
src="images/Client1_LogoPalette2_F0C06D.png"
|
|
||||||
alt="Bloom Valley Nursery Logo"/>
|
|
||||||
</div>
|
|
||||||
<h1>Bloom Valley Nursery</h1>
|
|
||||||
<!-- Navigation Bar -->
|
|
||||||
<nav role="navigation" aria-label="Main Navigation">
|
|
||||||
<ul>
|
|
||||||
<li>
|
|
||||||
<a href="index.html" aria-current="page" class="current-page">Home</a></li>
|
|
||||||
<li><a href="gallery.html">Gallery</a></li>
|
|
||||||
<li><a href="about.html">About Us</a></li>
|
|
||||||
<li><a href="community.html">Community Events</a></li>
|
|
||||||
</ul>
|
|
||||||
<div>
|
|
||||||
<button
|
|
||||||
id="shopping-cart"
|
|
||||||
aria-label="Open shopping cart"
|
|
||||||
class="fa-solid fa-cart-shopping fa-2xl">
|
|
||||||
</button>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
</header>
|
|
||||||
|
|
||||||
<!-- Main Content Section -->
|
|
||||||
<main role="main" id="main-index">
|
|
||||||
<aside id="left-aside">
|
|
||||||
<div id="perks-feature-container" aria-label="Reasons for Shopping With Bloom Valley Nursery">
|
|
||||||
<h2 id="perks-heading">Shopper Perks</h2>
|
|
||||||
<div class="perk-item" aria-label="Perk">
|
|
||||||
<h3>- 50% Off Deal -</h3>
|
|
||||||
<p>New subscribers to our newsletter this month will receive a coupon for 50% off their first purchase! Click here for details! Terms and conditions apply.</p>
|
|
||||||
</div>
|
|
||||||
<div class="perk-item" aria-label="Perk">
|
|
||||||
<h3>Exceptional Quality</h3>
|
|
||||||
<p>Every plant is carefully cultivated from seed or bulb to maturity, offering you vibrant, healthy specimens.</p>
|
|
||||||
</div>
|
|
||||||
<div class="perk-item" aria-label="Perk">
|
|
||||||
<h3>Expert Guidance</h3>
|
|
||||||
<p>Our knowledgeable team is here to help, from selecting the perfect plants to offering planting tips.</p>
|
|
||||||
</div>
|
|
||||||
<div class="perk-item" aria-label="Perk">
|
|
||||||
<h3>Eco-Friendly Practices</h3>
|
|
||||||
<p>We prioritize sustainability by using environmentally conscious growing methods, so you can feel good about your choices.</p>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div id="testimonials-feature" aria-label="Customer Testimonials About Their Experience With Bloom Valley Nursery.">
|
|
||||||
<h2>What Others Say</h2>
|
|
||||||
<div class="testimonial-container">
|
|
||||||
<div class="testimonial" aria-label="Customer Testimonial.">
|
|
||||||
<p>"My order arrived the very next day. The speed of delivery and high-quality products provided by Bloom Valley Nursery helped my project go smoothly from start to finish!"</p>
|
|
||||||
<h3>- Caroline N.</h3>
|
|
||||||
</div>
|
|
||||||
<div class="testimonial" aria-label="Customer Testimonial.">
|
|
||||||
<p>"Thanks to the Gardening 101 Workshop with Bethany and Bloom Valley Nursery's amazing line of products, I won 'Best Azaleas' at the 2024 Royal Horticultural Society's American Cup!"</p>
|
|
||||||
<h3>- Morris F.</h3>
|
|
||||||
</div>
|
|
||||||
<div class="testimonial" aria-label="Customer Testimonial.">
|
|
||||||
<p>"Bloom Valley Nursery's community garden inspired me take charge of my health. I was able to lose 50 pounds!"</p>
|
|
||||||
<h3>- Gladis B.</h3>
|
|
||||||
</div>
|
|
||||||
</div> </div>
|
|
||||||
</aside>
|
|
||||||
<!--<div id="featured-images">
|
|
||||||
<div class="featured-item">
|
|
||||||
<img src="image1.jpg" alt="Feature 1">
|
|
||||||
</div>-->
|
|
||||||
<section id="featured-container" aria-label="Featured items of the week">
|
|
||||||
<h2> This Week's Featured Items</h2>
|
|
||||||
<ul id="featured-images" aria-label="Images of this week's featured items">
|
|
||||||
<li><a href="gallery.html" id="featured-aloe-plant">
|
|
||||||
<img src="images/indoor/AloePlant.png" alt="An Aloe Vera plant in a turquoise ceramic planter." class="featured-item">Aloe Vera / Turquoise Planter</a></li>
|
|
||||||
<li><a href="gallery.html" id="featured-bird-house">
|
|
||||||
<img src="images/accessories/BirdHouse.png" alt="A handmade wooden birdhouse painted blue." class="featured-item">Handmade Wooden Birdhouse - Blue</a></li>
|
|
||||||
<li><a href="gallery.html" id="featured-apple-tree">
|
|
||||||
<img src="images/trees/AppleTree.png" alt="A Red Gala apple sapling in a burlap wrap." class="featured-item">Red Gala Apple Sapling - Burlap Bound</a></li>
|
|
||||||
<li><a href="gallery.html" id="featured-potting-soil">
|
|
||||||
<img src="images/accessories/PottingSoil.png" alt="A 10 lbs bag of potting soil." class="featured-item">Potting Soil - 10 lbs Bag</a></li>
|
|
||||||
<li><a href="gallery.html" id="featured-spider-plant">
|
|
||||||
<img src="images/indoor/SpiderPlant.png" alt="A Spider plant in a light gray ceramic planter." class="featured-item">Spider Plant / Light Gray Planter</a></li>
|
|
||||||
<li><a href="gallery.html" id="featured-birch-tree">
|
|
||||||
<img src="images/trees/BirchTree.png" alt="A Silver Birch sapling in a disposable plastic container." class="featured-item">Silver Birch Sapling - Containerized</a></li>
|
|
||||||
<li><a href="gallery.html" id="featured-watering-can">
|
|
||||||
<img src="images/accessories/WateringCan.png" alt="A blue painted aluminum watering can." class="featured-item">Painted Aluminum Watering Can - Blue</a></li>
|
|
||||||
<li><a href="gallery.html" id="featured-string-of-pearls">
|
|
||||||
<img src="images/indoor/StringofPearls.png" alt="String-of-pearls plant in hanging white ceramic planter." class="featured-item">String-of-Pearls Plant / Hanging White Planter</a></li>
|
|
||||||
<li><a href="gallery.html" id="featured-maple-tree">
|
|
||||||
<img src="images/trees/MapleTree.png" alt="A Japanese Maple sapling in a burlap wrap." class="featured-item">Japanese Maple Sapling - Burlap Bound</a></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<aside id="right-aside">
|
|
||||||
<div id="category-nav-container" aria-label="Available Product Categories">
|
|
||||||
<h2>Shop by Category</h2>
|
|
||||||
<div class="categories">
|
|
||||||
<ul>
|
|
||||||
<li><a href="gallery.html?category=trees#" class="cat-btn">Trees</a></li>
|
|
||||||
<li><a href="gallery.html?category=shrubs#" class="cat-btn">Shrubs</a></li>
|
|
||||||
<li><a href="gallery.html?category=indoor#" class="cat-btn">Indoor</a></li>
|
|
||||||
<li><a href="gallery.html?category=patio#" class="cat-btn">Patio</a></li>
|
|
||||||
<li><a href="gallery.html?category=tools#" class="cat-btn">Tools</a></li>
|
|
||||||
<li><a href="gallery.html?category=accessories#" class="cat-btn">Accessories</a></li>
|
|
||||||
<li><a href="gallery.html?category=landscaping#" class="cat-btn">Landscaping</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</aside>
|
|
||||||
<!-- Content specific to this page goes here -->
|
|
||||||
</main>
|
|
||||||
|
|
||||||
<!-- Footer Section -->
|
|
||||||
<footer role="contentinfo">
|
|
||||||
<div id="newsletter-container">
|
|
||||||
<label for="email-input" class="hidden">Enter your email to subscribe to our newsletter</label>
|
|
||||||
<form id="newsletter-form">
|
|
||||||
<input
|
|
||||||
type="email"
|
|
||||||
id="email-input"
|
|
||||||
aria-label="Enter your email to Subscribe"
|
|
||||||
placeholder="Subscribe@BloomValleyNursery.com"
|
|
||||||
/>
|
|
||||||
<button id="submit-btn" type="submit" aria-label="Submit the subscribe form">
|
|
||||||
Subscribe Now!
|
|
||||||
</button>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
<div id="footer-nav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="index.html" class="current-page">Home</a></li>
|
|
||||||
<li><a href="gallery.html">Gallery</a></li>
|
|
||||||
<li><a href="about.html">About Us</a></li>
|
|
||||||
<li><a href="community.html">Community Events</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
<div id="social-media">
|
|
||||||
<p>Check us out on social media!</p>
|
|
||||||
<ul class="social-icons">
|
|
||||||
<li id="pinterest">
|
|
||||||
<a href="#" aria-label="Follow us on Pinterest"
|
|
||||||
><i class="fa-brands fa-square-pinterest fa-lg"></i></a></li>
|
|
||||||
<li id="facebook">
|
|
||||||
<a href="#" aria-label="Follow us on Facebook"
|
|
||||||
><i class="fa-brands fa-facebook fa-lg"></i
|
|
||||||
></a>
|
|
||||||
</li>
|
|
||||||
<li id="instagram">
|
|
||||||
<a href="#" aria-label="Follow us on Instagram"
|
|
||||||
><i class="fa-brands fa-instagram fa-lg"></i
|
|
||||||
></a>
|
|
||||||
</li>
|
|
||||||
<li id="twitter">
|
|
||||||
<a href="#" aria-label="Follow us on X (Twitter)"
|
|
||||||
><i class="fa-brands fa-square-x-twitter fa-lg"></i
|
|
||||||
></a>
|
|
||||||
</li>
|
|
||||||
<li id="youtube">
|
|
||||||
<a href="#" aria-label="View our Youtube channel"
|
|
||||||
><i class="fa-brands fa-youtube fa-lg"></i
|
|
||||||
></a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
<div id="copyright">© 2024 Bloom Valley Nursery</div>
|
|
||||||
</footer>
|
|
||||||
<!-- Custom Newsletter Modal -->
|
|
||||||
<div id="custom-alert" class="modal hidden">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal" id="alert-close-btn">×</span>
|
|
||||||
<p id="alert-message"></p>
|
|
||||||
<button id="alert-ok-button">OK</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Modal for Shopping Cart -->
|
|
||||||
<div id="cart-modal" class="modal" style="display: none;">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal">×</span>
|
|
||||||
<h2>Your Shopping Cart</h2>
|
|
||||||
<ul id="cart-items"></ul> <!-- Dynamically populated -->
|
|
||||||
<p id="cart-total"></p> <!-- Sub-total will appear here -->
|
|
||||||
<div class="modal-buttons">
|
|
||||||
<button id="clear-cart-modal-btn">Clear Cart</button>
|
|
||||||
<button id="process-order-modal-btn">Process Order</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Modal for Item Added -->
|
|
||||||
<div id="item-added-modal" class="modal" style="display: none;">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal" id="item-added-close">×</span>
|
|
||||||
<p id="item-added-message"></p> <!-- Dynamically set message -->
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Confirmation Modal -->
|
|
||||||
<div id="confirmation-modal" class="modal" style="display: none;">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal" id="confirmation-close-btn">×</span>
|
|
||||||
<p id="confirmation-message"></p> <!-- Dynamic confirmation message -->
|
|
||||||
<button id="confirmation-confirm-btn">Confirm</button>
|
|
||||||
<button id="confirmation-close-btn">Close</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Final Confirmation Modal -->
|
|
||||||
<div id="final-confirmation-modal" class="modal" style="display: none;">
|
|
||||||
<div class="modal-content">
|
|
||||||
<span class="close-modal" id="final-confirmation-close-btn">×</span>
|
|
||||||
<p id="final-confirmation-message"></p> <!-- Message after successful action -->
|
|
||||||
<button id="final-confirmation-close-btn">Close</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- This loads after the page is read by browser -->
|
|
||||||
<script src="script.js"></script>
|
|
||||||
<script src="cart.js"></script>
|
|
||||||
<script src="newsletter.js"></script>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,50 +0,0 @@
|
||||||
document.addEventListener('DOMContentLoaded', () => {
|
|
||||||
const newsletterForm = document.getElementById('newsletter-form');
|
|
||||||
const emailInput = document.getElementById('email-input');
|
|
||||||
const alertBox = document.getElementById('custom-alert');
|
|
||||||
const alertMessage = document.getElementById('alert-message');
|
|
||||||
const alertOkButton = document.getElementById('alert-ok-button');
|
|
||||||
const alertCloseButton = document.getElementById('alert-close-btn');
|
|
||||||
|
|
||||||
// Form submission handler
|
|
||||||
newsletterForm.addEventListener('submit', (event) => {
|
|
||||||
event.preventDefault(); // Prevent form from submitting and refreshing the page
|
|
||||||
|
|
||||||
const email = emailInput.value.trim();
|
|
||||||
const emailRegex = /^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/;
|
|
||||||
|
|
||||||
// Check if email is valid
|
|
||||||
if (!emailRegex.test(email)) {
|
|
||||||
showCustomAlert('Please enter a valid email address.');
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Show success message
|
|
||||||
showCustomAlert(`Thank you for subscribing, ${email}!`);
|
|
||||||
newsletterForm.reset(); // Clear the input field after submission
|
|
||||||
});
|
|
||||||
|
|
||||||
// Function to show the custom alert modal
|
|
||||||
function showCustomAlert(message) {
|
|
||||||
alertMessage.textContent = message; // Set the alert message
|
|
||||||
alertBox.classList.remove('hidden'); // Show the alert modal
|
|
||||||
alertBox.style.display = 'flex'; // Ensure the modal is displayed
|
|
||||||
|
|
||||||
// Close the modal when the "OK" button is clicked
|
|
||||||
alertOkButton.addEventListener('click', closeCustomAlert);
|
|
||||||
alertCloseButton.addEventListener('click', closeCustomAlert);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Function to hide the custom alert modal
|
|
||||||
function closeCustomAlert() {
|
|
||||||
alertBox.classList.add('hidden'); // Hide the alert modal
|
|
||||||
alertBox.style.display = 'none'; // Ensure the modal is hidden
|
|
||||||
}
|
|
||||||
|
|
||||||
// Close the modal if clicking outside the modal content
|
|
||||||
window.addEventListener('click', (event) => {
|
|
||||||
if (event.target === alertBox) {
|
|
||||||
closeCustomAlert();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
});
|
|
|
@ -1,20 +0,0 @@
|
||||||
{
|
|
||||||
"name": "stackblitz-starters-rdsfw2",
|
|
||||||
"lockfileVersion": 3,
|
|
||||||
"requires": true,
|
|
||||||
"packages": {
|
|
||||||
"": {
|
|
||||||
"dependencies": {
|
|
||||||
"servor": "^4.0.2"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/servor": {
|
|
||||||
"version": "4.0.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/servor/-/servor-4.0.2.tgz",
|
|
||||||
"integrity": "sha512-MlmQ5Ntv4jDYUN060x/KEmN7emvIqKMZ9OkM+nY8Bf2+KkyLmGsTqWLyAN2cZr5oESAcH00UanUyyrlS1LRjFw==",
|
|
||||||
"bin": {
|
|
||||||
"servor": "cli.js"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -1,8 +0,0 @@
|
||||||
{
|
|
||||||
"scripts": {
|
|
||||||
"start": "servor --reload"
|
|
||||||
},
|
|
||||||
"dependencies": {
|
|
||||||
"servor": "^4.0.2"
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -1,106 +0,0 @@
|
||||||
document.addEventListener("DOMContentLoaded", () => {
|
|
||||||
// Shopper Perks Carousel
|
|
||||||
const perks = document.querySelectorAll(".perk-item");
|
|
||||||
let currentIndexPerks = 0;
|
|
||||||
|
|
||||||
function showNextPerk() {
|
|
||||||
// Hide all perks
|
|
||||||
perks.forEach(perk => {
|
|
||||||
perk.classList.remove("visible"); // Hide by removing 'visible' class
|
|
||||||
perk.style.display = "none"; // Set display to none
|
|
||||||
});
|
|
||||||
|
|
||||||
// Show the current perk
|
|
||||||
perks[currentIndexPerks].classList.add("visible"); // Show current perk by adding 'visible' class
|
|
||||||
perks[currentIndexPerks].style.display = "block"; // Explicitly set display to block
|
|
||||||
|
|
||||||
console.log(`Showing perk ${currentIndexPerks}`); // Debugging line
|
|
||||||
|
|
||||||
// Move to the next perk, loop back to the start if at the end
|
|
||||||
currentIndexPerks = (currentIndexPerks + 1) % perks.length;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Show the first perk initially
|
|
||||||
showNextPerk();
|
|
||||||
|
|
||||||
// Set an interval to cycle through the perks every 2.25 seconds (2250ms)
|
|
||||||
setInterval(showNextPerk, 2250);
|
|
||||||
|
|
||||||
// Customer Highlights Carousel
|
|
||||||
const testimonials = document.querySelectorAll(".testimonial");
|
|
||||||
let currentIndexTestimonials = 0;
|
|
||||||
|
|
||||||
console.log("Testimonials found: ", testimonials.length); // Debugging line
|
|
||||||
|
|
||||||
function showNextTestimonial() {
|
|
||||||
// Hide all testimonials
|
|
||||||
testimonials.forEach(testimonial => {
|
|
||||||
testimonial.classList.remove("visible"); // Remove 'visible' class
|
|
||||||
testimonial.style.display = "none"; // Set display to none
|
|
||||||
});
|
|
||||||
|
|
||||||
// Show the current testimonial
|
|
||||||
testimonials[currentIndexTestimonials].classList.add("visible"); // Add 'visible' class to show current testimonial
|
|
||||||
testimonials[currentIndexTestimonials].style.display = "block"; // Explicitly set display to block
|
|
||||||
|
|
||||||
console.log(`Showing testimonial ${currentIndexTestimonials}`); // Debugging line
|
|
||||||
|
|
||||||
// Move to the next testimonial, loop back to the start if at the end
|
|
||||||
currentIndexTestimonials = (currentIndexTestimonials + 1) % testimonials.length;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Show the first testimonial initially
|
|
||||||
showNextTestimonial();
|
|
||||||
|
|
||||||
// Set an interval to cycle through the testimonials every 3.5 seconds (3500ms)
|
|
||||||
setInterval(showNextTestimonial, 3500);
|
|
||||||
|
|
||||||
// Featured Items Carousel
|
|
||||||
const featuredItems = document.querySelectorAll("#featured-images .featured-item");
|
|
||||||
let currentIndex = 0;
|
|
||||||
|
|
||||||
function showNextItem() {
|
|
||||||
// Remove the 'active' class from the current image
|
|
||||||
featuredItems[currentIndex].classList.remove("active");
|
|
||||||
|
|
||||||
// Move to the next index, looping back to the start if necessary
|
|
||||||
currentIndex = (currentIndex + 1) % featuredItems.length;
|
|
||||||
|
|
||||||
// Add the 'active' class to the next image
|
|
||||||
featuredItems[currentIndex].classList.add("active");
|
|
||||||
}
|
|
||||||
|
|
||||||
// Initially show the first image by adding 'active' class
|
|
||||||
featuredItems[currentIndex].classList.add("active");
|
|
||||||
|
|
||||||
// Cycle through images every 3 seconds
|
|
||||||
setInterval(showNextItem, 3000);
|
|
||||||
});
|
|
||||||
|
|
||||||
// Featured Items Carousel
|
|
||||||
const featuredItems = document.querySelectorAll("#featured-images .featured-item");
|
|
||||||
let currentIndexFeatured = 0;
|
|
||||||
|
|
||||||
function updateFeaturedImages() {
|
|
||||||
featuredItems.forEach((item, index) => {
|
|
||||||
// Hide the text inside each <a> tag by setting the text's display to 'none'
|
|
||||||
const text = item.closest('a');
|
|
||||||
if (text) text.style.display = (index === currentIndexFeatured ? "block" : "none");
|
|
||||||
|
|
||||||
// Show only the active image by setting display to block for the current image
|
|
||||||
const image = item;
|
|
||||||
image.style.display = (index === currentIndexFeatured ? "block" : "none");
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
// Show next featured image
|
|
||||||
function showNextFeatured() {
|
|
||||||
currentIndexFeatured = (currentIndexFeatured + 1) % featuredItems.length; // Loop to the start
|
|
||||||
updateFeaturedImages();
|
|
||||||
}
|
|
||||||
|
|
||||||
// Initialize featured items carousel by showing the first image
|
|
||||||
updateFeaturedImages();
|
|
||||||
|
|
||||||
// Set up automatic cycling every 3 seconds
|
|
||||||
setInterval(showNextFeatured, 3000);
|
|