I bought a template on the marketplace, but the accordion module isn't responsive. Is there code I can use to make it responsive for mobile? The module script is below. Thanks!
<script> $(document).ready(function() { var $accordion = $('.accordion');
// Initially hide all accordion content $accordion.find('.accordion_text').hide(); // Initially display the accordion content with .expand class $accordion.find('.accordion_group.expand .accordion_text').show();
// Hide the displayed sibling accordion content so only one appears at a time $accordion.find(".accordion_header").not(this).parent(".accordion_group.expand").removeClass('expand').children('.accordion_text').stop(true,true).slideUp();
if(!$(this).parent('.accordion_group').hasClass('expand')){ // Display the accordion content if it is not displayed $(this).parent(".accordion_group").addClass('expand').children('.accordion_text').stop(true,true).slideDown(); } else{ // Hide the accordion content if it is displayed //$(this).parent(".accordion_group").removeClass('expand').children('.accordion_text').stop(true,true).slideUp(); } }); }); </script>