document.addEventListener('DOMContentLoaded', function () {
// Alle Akkordeon-Abschnitte überwachen
document.querySelectorAll('[id^="akkordion-standard-abschnitt-1"]').forEach(function (tab) {
tab.addEventListener('click', function () {
// Hole die Nummer aus der ID (z.B. "1" aus "akkordion-standard-abschnitt-1")
var idNum = this.id.split('1').pop();
// Verstecke alle Bilder
document.querySelectorAll('[id^="akkordion-standard-img-"]').forEach(function (img) {
img.style.display = 'none';
});
// Zeige das passende Bild
var imgToShow = document.getElementById('akkordion-standard-img-' + 1);
if (imgToShow) {
imgToShow.style.display = 'block';
}
});
});
});
document.addEventListener('DOMContentLoaded', function () {
document.querySelectorAll('[id^="akkordion-standard-abschnitt-2"]').forEach(function (tab) {
tab.addEventListener('click', function () {
var idNum = this.id.split('2').pop();
document.querySelectorAll('[id^="akkordion-standard-img-"]').forEach(function (img) {
img.style.display = 'none';
});
var imgToShow = document.getElementById('akkordion-standard-img-' + 2);
if (imgToShow) {
imgToShow.style.display = 'block';
}
});
});
});
document.addEventListener('DOMContentLoaded', function () {
document.querySelectorAll('[id^="akkordion-standard-abschnitt-3"]').forEach(function (tab) {
tab.addEventListener('click', function () {
var idNum = this.id.split('3').pop();
document.querySelectorAll('[id^="akkordion-standard-img-"]').forEach(function (img) {
img.style.display = 'none';
});
var imgToShow = document.getElementById('akkordion-standard-img-' + 3);
if (imgToShow) {
imgToShow.style.display = 'block';
}
});
});
});
document.addEventListener('DOMContentLoaded', function () {
document.querySelectorAll('[id^="akkordion-standard-abschnitt-4"]').forEach(function (tab) {
tab.addEventListener('click', function () {
var idNum = this.id.split('4').pop();
document.querySelectorAll('[id^="akkordion-standard-img-"]').forEach(function (img) {
img.style.display = 'none';
});
var imgToShow = document.getElementById('akkordion-standard-img-' + 4);
if (imgToShow) {
imgToShow.style.display = 'block';
}
});
});
});
document.addEventListener('DOMContentLoaded', function () {
document.querySelectorAll('[id^="akkordion-standard-abschnitt-5"]').forEach(function (tab) {
tab.addEventListener('click', function () {
var idNum = this.id.split('5').pop();
document.querySelectorAll('[id^="akkordion-standard-img-"]').forEach(function (img) {
img.style.display = 'none';
});
var imgToShow = document.getElementById('akkordion-standard-img-' + 5);
if (imgToShow) {
imgToShow.style.display = 'block';
}
});
});
});
document.addEventListener('DOMContentLoaded', function () {
// Alle Akkordeon-Abschnitte überwachen
document.querySelectorAll('[id^="akkordion-erweitert-abschnitt-1"]').forEach(function (tab) {
tab.addEventListener('click', function () {
// Hole die Nummer aus der ID (z.B. "1" aus "akkordion-standard-abschnitt-1")
var idNum = this.id.split('1').pop();
// Verstecke alle Bilder
document.querySelectorAll('[id^="akkordion-erweitert-img-"]').forEach(function (img) {
img.style.display = 'none';
});
// Zeige das passende Bild
var imgToShow = document.getElementById('akkordion-erweitert-img-' + 1);
if (imgToShow) {
imgToShow.style.display = 'block';
}
});
});
});
document.addEventListener('DOMContentLoaded', function () {
// Alle Akkordeon-Abschnitte überwachen
document.querySelectorAll('[id^="akkordion-erweitert-abschnitt-2"]').forEach(function (tab) {
tab.addEventListener('click', function () {
// Hole die Nummer aus der ID (z.B. "1" aus "akkordion-standard-abschnitt-1")
var idNum = this.id.split('2').pop();
// Verstecke alle Bilder
document.querySelectorAll('[id^="akkordion-erweitert-img-"]').forEach(function (img) {
img.style.display = 'none';
});
// Zeige das passende Bild
var imgToShow = document.getElementById('akkordion-erweitert-img-' + 2);
if (imgToShow) {
imgToShow.style.display = 'block';
}
});
});
});
document.addEventListener('DOMContentLoaded', function () {
// Alle Akkordeon-Abschnitte überwachen
document.querySelectorAll('[id^="akkordion-erweitert-abschnitt-3"]').forEach(function (tab) {
tab.addEventListener('click', function () {
// Hole die Nummer aus der ID (z.B. "1" aus "akkordion-erweitert-abschnitt-1")
var idNum = this.id.split('3').pop();
// Verstecke alle Bilder
document.querySelectorAll('[id^="akkordion-erweitert-img-"]').forEach(function (img) {
img.style.display = 'none';
});
// Zeige das passende Bild
var imgToShow = document.getElementById('akkordion-erweitert-img-' + 3);
if (imgToShow) {
imgToShow.style.display = 'block';
}
});
});
});
document.addEventListener('DOMContentLoaded', function () {
// Alle Akkordeon-Abschnitte überwachen
document.querySelectorAll('[id^="akkordion-erweitert-abschnitt-4"]').forEach(function (tab) {
tab.addEventListener('click', function () {
// Hole die Nummer aus der ID (z.B. "1" aus "akkordion-erweitert-abschnitt-1")
var idNum = this.id.split('4').pop();
// Verstecke alle Bilder
document.querySelectorAll('[id^="akkordion-erweitert-img-"]').forEach(function (img) {
img.style.display = 'none';
});
// Zeige das passende Bild
var imgToShow = document.getElementById('akkordion-erweitert-img-' + 4);
if (imgToShow) {
imgToShow.style.display = 'block';
}
});
});
});
document.addEventListener('DOMContentLoaded', function () {
// Alle Akkordeon-Abschnitte überwachen
document.querySelectorAll('[id^="akkordion-erweitert-abschnitt-5"]').forEach(function (tab) {
tab.addEventListener('click', function () {
// Hole die Nummer aus der ID (z.B. "1" aus "akkordion-erweitert-abschnitt-1")
var idNum = this.id.split('5').pop();
// Verstecke alle Bilder
document.querySelectorAll('[id^="akkordion-erweitert-img-"]').forEach(function (img) {
img.style.display = 'none';
});
// Zeige das passende Bild
var imgToShow = document.getElementById('akkordion-erweitert-img-' + 5);
if (imgToShow) {
imgToShow.style.display = 'block';
}
});
});
});
document.addEventListener('DOMContentLoaded', function () {
// Alle Akkordeon-Abschnitte überwachen
document.querySelectorAll('[id^="akkordion-erweitert-abschnitt-6"]').forEach(function (tab) {
tab.addEventListener('click', function () {
// Hole die Nummer aus der ID (z.B. "1" aus "akkordion-erweitert-abschnitt-1")
var idNum = this.id.split('6').pop();
// Verstecke alle Bilder
document.querySelectorAll('[id^="akkordion-erweitert-img-"]').forEach(function (img) {
img.style.display = 'none';
});
// Zeige das passende Bild
var imgToShow = document.getElementById('akkordion-erweitert-img-' + 6);
if (imgToShow) {
imgToShow.style.display = 'block';
}
});
});
});
document.addEventListener('DOMContentLoaded', function () {
// Alle Akkordeon-Abschnitte überwachen
document.querySelectorAll('[id^="akkordion-erweitert-abschnitt-7"]').forEach(function (tab) {
tab.addEventListener('click', function () {
// Hole die Nummer aus der ID (z.B. "1" aus "akkordion-erweitert-abschnitt-1")
var idNum = this.id.split('7').pop();
// Verstecke alle Bilder
document.querySelectorAll('[id^="akkordion-erweitert-img-"]').forEach(function (img) {
img.style.display = 'none';
});
// Zeige das passende Bild
var imgToShow = document.getElementById('akkordion-erweitert-img-' + 7);
if (imgToShow) {
imgToShow.style.display = 'block';
}
});
});
});