dompdf character encoding UTF-8

后端 未结 11 2061
我在风中等你
我在风中等你 2020-12-01 21:07

Im trying to create pdf with correct characters, but there are \"?\" chars. I created a test php file, where Im trying to fing the best solution. If Im open in the browser t

11条回答
  •  长情又很酷
    2020-12-01 21:21

    I had the same problem and I solved it very simple. Just import google fonts with required language subset in your CSS file which is used when generating HTML. Specify utf-8 in your HTML file and it's working...

    @import url('https://fonts.googleapis.com/css?family=Roboto:400,700&subset=latin-ext');
    body {font-family: 'Roboto', sans-serif;}
    

提交回复
热议问题