Jump to content

Accordion Markdown Block Not Loading On First Refresh

Recommended Posts

Hi,

Here's a quick snippet of my issue: https://www.loom.com/share/3661f44cb9314cc1aa9b4aa76d3e17b6

Website: https://troopprofilepage.squarespace.com/

Unfortunately, I can not share the website info due to NDA. 

Markdown Block Information:

<script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>

<script>
    $(document).ready(function(){
    $('.markdown-block .sqs-block-content h3').css('cursor','pointer');
    $(".markdown-block .sqs-block-content h3").nextUntil("h3").slideToggle();
    $(".markdown-block .sqs-block-content h3").click(function() {$(this).nextUntil("h3").slideToggle();});
    });
    </script>

 

Any help would be appreciated!

Link to comment
  • Replies 1
  • Views 209
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Without being able to see the page that is pulling the info in from the blog I don't think there is much we can do to help. If you can't show actual site data because of NDA, can you set up example pages that show the problem with some lorem ipsum text. If not on the site itself then on a trial site?

A few suggestions. Use code blocks instead of embed blocks for the code. Update your jQuery. The version you have installed is ancient. The current version is 3.6.4. Do keep the old line around until you've tested the code with the new version.

Find my contributions useful? Please like, upvote, mark my answer as the best ( solution ), and see my profile. Thanks for your support! I am a Squarespace ( and other technological things ) consultant open for new projects.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment


×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.