Jump to content

Custom font not showing on other browsers

Recommended Posts

Site URL: https://tgtkb.squarespace.com

Hi,
Bit of a newbie question, and from someone who isn't too familiar with CSS!
I'm trying to use a custom font on my site: https://tgtkb.squarespace.com (no password). It displays great on my browser/machine but not on anyone I've shared it with. I've used the following code:

----------------

@font-face {
    font-family: ‘Trap’;
    src: url(https://static1.squarespace.com/static/61dee34ed473a2098445cfc0/t/61dee6997e587357fb96ad94/1641997977602/Trap-Regular.woff);
}
h1, h2, h3, h4, p {font-family: 'Trap' !important}

.quantity-label {
  font-family: Trap;}

.sqs-add-to-cart-button-inner {
  font-family: Trap;}

.product-quantity-input  {
  font-family: Trap;}

.Quantity {
  font-family: Trap;}

.header-nav *, nav.header-menu-nav-list * {
  font-family: Trap;}

@media screen and (max-width: 640px) {
h1 {
    font-size: 40px !important;
  }}

 

 

----------------

There's some additional CSS in there for font size as well as forcing the font in certain other areas of the site, but can anyone shed any light on where I'm going wrong? Like I say it looks great on my browser, but imagine that's because I've got the font installed locally maybe?

TIA

Andy

 

 

Edited by Drumbeat
Link to comment
  • Replies 2
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Your code is invalid, use this new code

@font-face {
    font-family: Trap;
    src: url(https://static1.squarespace.com/static/61dee34ed473a2098445cfc0/t/61dee6997e587357fb96ad94/1641997977602/Trap-Regular.woff)
}
h1,h2,h3,h4,p, .quantity-label, .sqs-add-to-cart-button-inner, .product-quantity-input, .header-nav *,nav.header-menu-nav-list * {
    font-family: Trap !important;
}

 

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

How to: Setup Password & Share url Insert Custom CSS - Page Header - Upload Custom Font - Upload File - Find Block ID - Contact Customer Care

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.