Jump to content

Product Pages Displaying Differently

Recommended Posts

Site URL: https://grapefruit-fox-6gzs.squarespace.com/

Hello,

 

I have two stores on my site because I want one to show up on the navigation and one to be hidden. This is fine, but I noticed the product pages display differently on each store. For the ones under "shop" they display how I'd like them to (proper spacing, markdowns, ect). However, the ones under "create" are formatted all wrong. Ideally, I'd like the "create" product listings to look the same as the "shop" product listings. 

 

We used Javascript to make sure the product description showed up before the quantity. However, the javascript is only working on the "Shop" page and not the "Create" page. 

 

Here is the Javascript we used:

 

<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
<script>
  $(document).ready(function() { 
        $('section.ProductItem-additional').insertAfter('.ProductItem-details-excerpt');
    });
</script>
<style>
  section.ProductItem-summary {
    align-items: flex-start !important;
    margin-bottom: 0px !important;
}
  section.ProductItem-additional {
    margin-top: 0px !important;
    margin-bottom: 20px !important;
}
</style>

<script>
$(document).ready(function() {

 

The password to view my site is "help"

Link to comment
19 hours ago, tuanphan said:

Hi. Can you share link to 2 stores? We can check easier

Hi!

 

Here's a link to the store that shows the product descriptions how I'd like them to look:

https://grapefruit-fox-6gzs.squarespace.com/config/

 

And here's the store that shows them formatted weirdly when you click on the individual products:

https://grapefruit-fox-6gzs.squarespace.com/config/pages/60d9ecd1a3702b380bbbe566/categories/60d9ecd1a3702b380bbbe56a

 

Link to comment

@MeaghanPM

Excellent!

As an alternative the code could, instead adding the accordion after a specific element as is done now, append it to parent element of the specific element. The parent element is almost certainly always going to be there. Whereas its children may be turned on or off depending on certain circumstances.

Then you would use the CSS order property to control its order of appearance in relation to the other siblings.

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.