gpt4 book ai didi

coldfusion - CFDocument 和高位 ASCII 码?

转载 作者:行者123 更新时间:2023-12-03 23:50:40 26 4
gpt4 key购买 nike

我有一个使用 <cfdocument> 创建 PDF 的小脚本写一个PDF。它看起来像这样(最小化代码):

<cfdocument name="mypdf" format="pdf">
&#9746;
</cfdocument>

当我的数据包含像 &#9744; 这样的高 ASCII 字符时(☑) 我收到一个错误:

An exception occurred when performing document processing.



详细的错误信息是:

The cause of this exception was that: coldfusion.document.spi.DocumentExportException: coldfusion.document.DocumentFontException: An exception occurred when reading the font file c:\windows\fonts\EUB___.PFM The cause of this exception was that: java.awt.FontFormatException: Unsupported sfnt C:\WINDOWS\TEMP+~JF42977.tmp..



这似乎是字体问题!更改 CSS 字体并不能解决问题。我需要检查默认的系统字体...

哦,这不是 # ,我已经这样做了: &##9744;
我使用 ColdFusion 8。

最佳答案

如果我这样做:

<cfscript>
x = "before_______ &##9744; __________after";
</cfscript>

<cfdocument format="pdf">
<cfoutput>#x#</cfoutput>
</cfdocument>

我得到一个 pdf,内容为“before_ _ ____ _after”。

问题可能出在您代码的其他地方。

关于coldfusion - CFDocument 和高位 ASCII 码?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13951855/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com