Laravel:无法正确读取 ascii 文件(特殊字符)

问题描述 投票:0回答:0

我在从我的 S3 存储桶中读取 .txt 文件 (ascii) 时遇到问题。当我阅读它时,特殊字符显示为“?”。例如,当文件包含单词“Äpfel”时,它将被读取为“?pfel”。我该如何解决?

我的代码:

$contents = Storage::disk('s3')->get('test123.txt');
php laravel amazon-s3 ascii
© www.soinside.com 2019 - 2024. All rights reserved.