Issue
I am using an accordion style to display a set of information on a site. All correct information is displayed, but the accordion items are not collapsed. Please find my code below. Function and variable names may contain typos as I renamed them for privacy. Am I missing something in the accordion class? Are there any extra links needed in the HTML header to make it work?
Location:
blah1: /blah2:
well
somehow status
Something
Brabat
Bra Type
Something button
";
echo "${x} ";
echo "${blahStatus} ";
if ($blahNumber != "null") {
echo "${blahNumber} ";
echo "${blahLevel} ";
echo "${blahType} ";
}
other than that {
echo "N/A ";
echo "N/A ";
echo "N/A ";
}
if ($blahType == 5) {
echo "
";
}
otherwise ($blahType == 11) {
echo " ";
}
other than that {
echo "N/A ";
}
echo "\n";
}
?>
Solution
You also needs to include the bootstrap js files in your code in order to make accordion work properly, just include the below script:
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js" integrity="sha384-ka7Sk0Gln4gmtz2MlQnikT1wXgYsOg+OMhuP+IlRH9sENBO0LRn5q+8nbTov4+1p" crossorigin="anonymous"></script>
Answered By – Mohammad Ajram
Answer Checked By – Gilberto Lyons (Easybugfix Admin)