Jump to content

Using code to change the product price appearance

Go to solution Solved by paul2009,

Recommended Posts

Posted

Hi everyone

My client wants the product price showing in a certain way both at checkout and on the product page.

https://www.porta-bowl.co.uk/shop/p/porta-bowl

I've had to set the product price to £20.82 so it shows the price at checkout with VAT added to become £24.99.

I've used the following code, which gives me the result of the screenshot

Quote

 

.product-price:before { 
  content: '£24.99 (RRP) '; 
}

.product-price:AFTER { 
  content: '+ VAT';  
}

 

This is exactly how we need it, however how can I make the £24.99 (RRP) font size bigger, and then have the £20.82 + VAT underneath?

Screenshot 2024-01-25 at 10.37.05.png

  • Solution
Posted

If only one product will be sold on the website, you may want to consider using a standard layout page instead of living with the restrictions of the Store page? This will give you the flexibility to style it however you want to, without using code 🙂.

You can add the cart button to any page by adding a Product Block, and setting the style to only show the button, not the title, price and so on.

Did this help? Please give feedback by clicking an icon below  ⬇️

Me: I'm Paul, a SQSP user for >18 yrs & Circle Leader since 2017. I value honesty, transparency, diversity and good design ♥.
Work: Founder of SF.DIGITAL. We provide high quality original extensions to supercharge your Squarespace website. 
Content: Views and opinions are my own. Links in my posts may refer to my own SF.DIGITAL products or may be affiliate links.
Forum advice is completely free. You can thank me by selecting a feedback emoji. Buying a coffee is generous but optional.

Posted
4 hours ago, lauren-offpaper said:

Thanks so much, appreciate it!

You're welcome 🙂

Me: I'm Paul, a SQSP user for >18 yrs & Circle Leader since 2017. I value honesty, transparency, diversity and good design ♥.
Work: Founder of SF.DIGITAL. We provide high quality original extensions to supercharge your Squarespace website. 
Content: Views and opinions are my own. Links in my posts may refer to my own SF.DIGITAL products or may be affiliate links.
Forum advice is completely free. You can thank me by selecting a feedback emoji. Buying a coffee is generous but optional.

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.