Skip to content

Custom fonts #5

@helleholmsen

Description

@helleholmsen

I'm trying to load a custom font but it just wont work. The path to the font is correct and working. Any ideas to why this is?

{% set fontBold = siteUrl|slice(0,-1) ~ '/resources/fonts/TSTARPRO-Bold.ttf' %}

<html>
  <head>
    <meta http-equiv="content-type" content="text/html; charset=utf-8"/>
    <style>
      @font-face {
        font-family: "TSTARPRO";
        src: url({{ '"' ~ fontBold ~ '"' }}) format("truetype");
      }
      h1 {
        font-family: "TSTARPRO";
      }
    </style>
  </head>
  <body class="template-print-page">
    <h1 class="title">
      Zuccardi Polígonos Semillon
    </h1>
  </body>
</html>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions