document.addEventListener('DOMContentLoaded', function () {
// Get the product images container
var productMedia = document.querySelectorAll('.product-single__media-item');
// Get the variant dropdown or buttons
var variantSelectors = document.querySelectorAll('[name="id"]');
// Function to display the first product image
function showFirstImage() {
if (productMedia.length > 0) {
productMedia.forEach(function (media, index) {
if (index === 0) {
media.style.display = 'block';
} else {
media.style.display = 'none';
}
});
}
}
// Show the first image on page load
showFirstImage();
// Add event listeners to variant selectors
variantSelectors.forEach(function (selector) {
selector.addEventListener('change', function () {
showFirstImage();
});
});
});
document.addEventListener('DOMContentLoaded', function () {
// Get the product images container
var productMedia = document.querySelectorAll('.product-single__media-item');
// Get the variant dropdown or buttons
var variantSelectors = document.querySelectorAll('[name="id"]');
// Function to display the first product image
function showFirstImage() {
if (productMedia.length > 0) {
productMedia.forEach(function (media, index) {
if (index === 0) {
media.style.display = 'block';
} else {
media.style.display = 'none';
}
});
}
}
// Show the first image on page load
showFirstImage();
// Add event listeners to variant selectors
variantSelectors.forEach(function (selector) {
selector.addEventListener('change', function () {
showFirstImage();
});
});
});
document.addEventListener('DOMContentLoaded', function () {
// Get the product images container
var productMedia = document.querySelectorAll('.product-single__media-item');
// Get the variant dropdown or buttons
var variantSelectors = document.querySelectorAll('[name="id"]');
// Function to display the first product image
function showFirstImage() {
if (productMedia.length > 0) {
productMedia.forEach(function (media, index) {
if (index === 0) {
media.style.display = 'block';
} else {
media.style.display = 'none';
}
});
}
}
// Show the first image on page load
showFirstImage();
// Add event listeners to variant selectors
variantSelectors.forEach(function (selector) {
selector.addEventListener('change', function () {
showFirstImage();
});
});
});
document.addEventListener('DOMContentLoaded', function () {
// Get the product images container
var productMedia = document.querySelectorAll('.product-single__media-item');
// Get the variant dropdown or buttons
var variantSelectors = document.querySelectorAll('[name="id"]');
// Function to display the first product image
function showFirstImage() {
if (productMedia.length > 0) {
productMedia.forEach(function (media, index) {
if (index === 0) {
media.style.display = 'block';
} else {
media.style.display = 'none';
}
});
}
}
// Show the first image on page load
showFirstImage();
// Add event listeners to variant selectors
variantSelectors.forEach(function (selector) {
selector.addEventListener('change', function () {
showFirstImage();
});
});
});
document.addEventListener('DOMContentLoaded', function () {
// Get the product images container
var productMedia = document.querySelectorAll('.product-single__media-item');
// Get the variant dropdown or buttons
var variantSelectors = document.querySelectorAll('[name="id"]');
// Function to display the first product image
function showFirstImage() {
if (productMedia.length > 0) {
productMedia.forEach(function (media, index) {
if (index === 0) {
media.style.display = 'block';
} else {
media.style.display = 'none';
}
});
}
}
// Show the first image on page load
showFirstImage();
// Add event listeners to variant selectors
variantSelectors.forEach(function (selector) {
selector.addEventListener('change', function () {
showFirstImage();
});
});
});
document.addEventListener('DOMContentLoaded', function () {
// Get the product images container
var productMedia = document.querySelectorAll('.product-single__media-item');
// Get the variant dropdown or buttons
var variantSelectors = document.querySelectorAll('[name="id"]');
// Function to display the first product image
function showFirstImage() {
if (productMedia.length > 0) {
productMedia.forEach(function (media, index) {
if (index === 0) {
media.style.display = 'block';
} else {
media.style.display = 'none';
}
});
}
}
// Show the first image on page load
showFirstImage();
// Add event listeners to variant selectors
variantSelectors.forEach(function (selector) {
selector.addEventListener('change', function () {
showFirstImage();
});
});
});![Give your pup's bite a reality check with the Dog Safety Bite Stopper! This bite-stopping device gives your four-legged friend the bite resistance they need for safe playtime. With its snug fit and adjustable strap, your pup will be the king (or queen!) of the dog park without any problems from overly-enthusiastic jaw-jacking.](//dragoyle.com/cdn/shop/products/4140572885_812408436.jpg?v=1679879688&width=1445)
![Give your pup's bite a reality check with the Dog Safety Bite Stopper! This bite-stopping device gives your four-legged friend the bite resistance they need for safe playtime. With its snug fit and adjustable strap, your pup will be the king (or queen!) of the dog park without any problems from overly-enthusiastic jaw-jacking.](http://dragoyle.com/cdn/shop/products/3669037250_812408436.jpg?v=1679879688&width=1445)
![Give your pup's bite a reality check with the Dog Safety Bite Stopper! This bite-stopping device gives your four-legged friend the bite resistance they need for safe playtime. With its snug fit and adjustable strap, your pup will be the king (or queen!) of the dog park without any problems from overly-enthusiastic jaw-jacking.](http://dragoyle.com/cdn/shop/products/4140581687_812408436.jpg?v=1679879688&width=1445)
![Give your pup's bite a reality check with the Dog Safety Bite Stopper! This bite-stopping device gives your four-legged friend the bite resistance they need for safe playtime. With its snug fit and adjustable strap, your pup will be the king (or queen!) of the dog park without any problems from overly-enthusiastic jaw-jacking.](http://dragoyle.com/cdn/shop/products/3668084060_812408436.jpg?v=1679879688&width=1445)
![Give your pup's bite a reality check with the Dog Safety Bite Stopper! This bite-stopping device gives your four-legged friend the bite resistance they need for safe playtime. With its snug fit and adjustable strap, your pup will be the king (or queen!) of the dog park without any problems from overly-enthusiastic jaw-jacking.](http://dragoyle.com/cdn/shop/products/3668081099_812408436.jpg?v=1679879688&width=1445)
![Give your pup's bite a reality check with the Dog Safety Bite Stopper! This bite-stopping device gives your four-legged friend the bite resistance they need for safe playtime. With its snug fit and adjustable strap, your pup will be the king (or queen!) of the dog park without any problems from overly-enthusiastic jaw-jacking.](http://dragoyle.com/cdn/shop/products/2650107489009.jpg?v=1679879688&width=1445)
![Give your pup's bite a reality check with the Dog Safety Bite Stopper! This bite-stopping device gives your four-legged friend the bite resistance they need for safe playtime. With its snug fit and adjustable strap, your pup will be the king (or queen!) of the dog park without any problems from overly-enthusiastic jaw-jacking.](http://dragoyle.com/cdn/shop/products/4140572885_812408436.jpg?v=1679879688&width=1445)