최근 검색
최근 검색 없음

Jason McDonald
가입한 날짜: 2023년 2월 24일
·
마지막 활동: 2023년 2월 27일
팔로잉
0
팔로워
0
총 활동 수
6
투표 수
0
가입 플랜
1
활동 개요
배지
문서
게시물
커뮤니티 댓글
문서 댓글
활동 개요
님의 최근 활동 Jason McDonald
Jason McDonald님이 에 댓글을 입력함
댓글 보기 · 2023년 2월 27일에 게시됨 · Jason McDonald
0
팔로워
0
투표 수
0
댓글
Jason McDonald님이 에 댓글을 입력함
The only code I have added to the script.js file is
document.addEventListener('DOMContentLoaded', function() {
var acc = document.getElementsByClassName("accordion");
var i;
for (i = 0; i < acc.length; i++) {
acc[i].addEventListener("click", function() {
this.classList.toggle("active");
var panel = this.nextElementSibling;
if (panel.style.maxHeight) {
panel.style.maxHeight = null;
} else {
panel.style.maxHeight = panel.scrollHeight + "px";
}
});
}
});
We have multiple HC's for different brands and there's different content writers so I'm not sure what modifications have been made to this particular theme. As I said the accordion is working in other HC's we have.
Is there anyway to find out which part of the theme code is affecting this?
댓글 보기 · 2023년 2월 24일에 편집됨 · Jason McDonald
0
팔로워
0
투표 수
0
댓글
Jason McDonald님이 에 댓글을 입력함
Hello.
I've added the code Trapta provided at the beginning of the thread and this works perfectly in our sandbox HC.
When I tried doing it on our live environment it's not working. The accordion is here but clicking on it does not expand it.
댓글 보기 · 2023년 2월 24일에 게시됨 · Jason McDonald
0
팔로워
0
투표 수
0
댓글