2

So I've tried all kinds of things to get Dompdf to load my font. I downloaded them and put them in the folder and used the @font-face rule, I used google's import code, and I now have them as standard link tags. Unfortunately I still can't get them to load. Here's my code, can anyone help?:

    <!DOCTYPE html>
    <html>
    <head>


    <link href="https://fonts.googleapis.com/css?family=Source+Sans+Pro" rel="stylesheet">
    <link href="https://fonts.googleapis.com/css?family=Lora" rel="stylesheet">
    <style type="text/css">
    header div.right-text{
      color:#2364AA;font:'Lora',serif; font-weight: bold;font-size:50px;
    }
    </style>
    </head>
    <body>
    <header>

    <img src="<?php echo WP_CONTENT_DIR; ?>image.jpg" style="width:200px;float:left;margin-right:30px;" />
    <div class="right-text"><strong>Resident Directory</strong> <em><?php echo date('d M Y'); ?></em></div>

    </header>
    <?php while ( have_posts() ) : the_post(); ?>


        <!-- PAGE CONTENT : begin -->
        irrelevant
        <!-- PAGE CONTENT : end -->



    <?php endwhile; ?>
    <footer>
    </footer>
    </html>
nowox
  • 25,978
  • 39
  • 143
  • 293
scl
  • 93
  • 9
  • Dompdf doesn't even seem to work correctly when using the bundled DejaVu font. There's maybe a bug in parsing the CSS selector. Feel like [posting a bug report](https://github.com/dompdf/dompdf/issues/new)? – BrianS Aug 15 '17 at 23:52

0 Answers0