Jump to content

Code to move item from 'Additional Information' to below product description

Go to solution Solved by tuanphan,

Recommended Posts

Hi all.

I see this topic has been discussed a few times but I can't see a solution that fits. I wonder is anyone can help?

I have a social share tool (AddThis) embedded via a code block in the additional information section of a product page. I've used Json to move this into the product description, but I cannot place it where I want it to be.

Here is a screenshot of what I am trying to achieve and the code I have used within Code Injection -> Footer.

<!--- Moving Social Share Icons into description -------------->
<script>
  $(document).ready(function() { 
        $('section.ProductItem-additional').insertAfter('.ProductItem-details-excerpt');
    });
</script> 

image.thumb.jpeg.9b2b7193b6725fa4a4dd743e488d8f75.jpeg

 

URL - https://fiona-mcdonald.squarespace.com/collections/p/claude-bench
Password - fiona

If anyone knows the correct class to place it after, or reference to information, I would be hugely grateful.

Thanks in advance
Tom 

Link to comment
  • Replies 4
  • Views 371
  • Created
  • Last Reply

Top Posters In This Topic

Try this:

<!--- Moving Social Share Icons into description -------------->
<script>
  $(document).ready(function() { 
        $('section.ProductItem-additional').insertAfter('.ProductItem-details-checkout');
    });
</script> 

Please like and upvote if my comments were helpful to you. Cheers!

Zygmunt Spray
Squarespace Website Designer
Contact me: 
https://squarefortytwo.com 
Hire me on Upwork!

🔌 Ghost Squarespace Plugins (Referral link)
📈 SEO Space (Referral link)
 SquareWebsites Plugins (Referral link)
 🔲 SQSP Themes (Referral link) 
Spark Plugin (Referral link) 

 Did I help? Buy me a coffee?

Link to comment
  • Solution

Use this

<!--- Moving Social Share Icons into description -------------->
<script>
  $(document).ready(function() { 
        $('section.ProductItem-additional').insertAfter('.sqs-add-to-cart-button-wrapper>div');
    });
</script>
<style>
  .sqs-add-to-cart-button-wrapper:not([class*="sf"]) {
    display: block !important;
    order: 5 !important;
}
  .sqs-add-to-cart-button-wrapper:not([class*="sf"]) .sqs-add-to-cart-button {
    display: none !important;
}
</style>

 

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

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.