Jump to content

Adding font files and using custom fonts on individual pages

Recommended Posts

Site URL: https://emilycrowder.work/

Hi! I am attempting to make the subpages on my portfolio very custom. Each page is a different client project and therefore needs to be its own style in terms of font and color scheme. I'm having a hard time doing this. 

This is my homepage: https://emilycrowder.work/ (note that there is no header/menu bar. You can click on the hyperlinked text to go to each individual page)

As an example, I want to use Proxima Nova font on the Purell page: https://emilycrowder.work/purell

Following online guides, I put this code in the Design > Custom CSS space:

@font-face {
  font-family: "Purellfont";
  src: url(https://static1.squarespace.com/static/61688eafa024502ebe2c43e7/t/61b8fd1a96f28263a1f12d98/1639513370307/ProximaNova-Sbold.otf) format('otf')
}

Next, I went to Pages > Purell > gear icon > Advanced and put in the following code:

<style>

h2 {
    font-family: "Purellfont", sans-serif !important;
  }
  p {
    font-family: "Purellfont", sans-serif !important;
  }
</style>

I noticed that this code changed the fonts on the Purell page so that they are no longer the default font of Poppins; however, the Proxima Nova font is not being applied. I'm not sure what the placeholder is, but it's not the font I tried to install. 

I am a total coding novice so as much explanation as possible would be greatly appreciated. Thank you SO much!

Link to comment
4 hours ago, Emilysc said:

Site URL: https://emilycrowder.work/

Hi! I am attempting to make the subpages on my portfolio very custom. Each page is a different client project and therefore needs to be its own style in terms of font and color scheme. I'm having a hard time doing this. 

This is my homepage: https://emilycrowder.work/ (note that there is no header/menu bar. You can click on the hyperlinked text to go to each individual page)

As an example, I want to use Proxima Nova font on the Purell page: https://emilycrowder.work/purell

Following online guides, I put this code in the Design > Custom CSS space:

@font-face {
  font-family: "Purellfont";
  src: url(https://static1.squarespace.com/static/61688eafa024502ebe2c43e7/t/61b8fd1a96f28263a1f12d98/1639513370307/ProximaNova-Sbold.otf) format('otf')
}

Next, I went to Pages > Purell > gear icon > Advanced and put in the following code:

<style>

h2 {
    font-family: "Purellfont", sans-serif !important;
  }
  p {
    font-family: "Purellfont", sans-serif !important;
  }
</style>

I noticed that this code changed the fonts on the Purell page so that they are no longer the default font of Poppins; however, the Proxima Nova font is not being applied. I'm not sure what the placeholder is, but it's not the font I tried to install. 

I am a total coding novice so as much explanation as possible would be greatly appreciated. Thank you SO much!

If you want to apply font for an individual page, it is required to add the page id in your custom css code.

For example: setting for purel page, we set the following one

<style>

#collection-61a1182b4d0dd626ecceb147 h2 {
    font-family: "Purellfont", sans-serif !important;
  }
#collection-61a1182b4d0dd626ecceb147  p {
    font-family: "Purellfont", sans-serif !important;
  }
</style>

To find the right page id, i suggest using the Find ID in squarespace extension

image.thumb.png.28b48f220813653088d6b558c41a2991.png

Hope it helps you

Support me by pressing 👍 if this useful for you

BeyondSpace - Squarespace Website Developer

🖼️ Lightbox Studio (Enable Pinch/Zoom on lightbox)
🗓️ Delivery Date Picker (Squarespace Date picker form field)
💫 Gallery block 7.1 workaround
🥳 Sparkplugin Customisations Browsers (Browse +100 Spark plugin customisations)
🥳 Elfsight Template Browsers (Browse +1000 Elfsight widget Templates)

If you find my answer useful, let's leave a like or upvote so others with the same issue can find their solution. 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.