Laravel & DomPDF を使用してドキュメントを PDF にエクスポートしようとしています。これは私の Mac では機能しますが、ステージング サーバーやライブ サーバーでは機能しません。次のようなエラー:
これが何を意味するのかわからず、解決策が見つかりません。
iconv_strlen(): Wrong charset, conversion from
8bit//IGNORE' にUCS-4LE' is not allowed
open: /srv/www/html/vendor/patchwork/utf8/class/Patchwork/PHP/Shim/Mbstring.php
return true;
}
static function mb_strlen($s, $encoding = INF)
{
INF === $encoding && $encoding = self::$internal_encoding;
return iconv_strlen($s, $encoding . '//IGNORE');
}
以下を .htaccess に追加しようとしました
AddDefaultCharset UTF-8
私はpdfを生成しようとしているビューの一番上に以下を追加しようとしました:
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
デバッグに役立つ情報がさらに必要な場合は、コメントで質問してください。