我在网站上实现了一个vCard.问题是虽然在Windows上没有正确解析特殊字符.
我可以让它在Mac上正常工作,但是一旦我在Windows(Windows Contacts)中打开一个vcf,它就会搞砸了.当我在记事本中打开vcf时,它会正常显示字符.
我尝试了所有可以找到的vcf版本(2.1,3.0,4.0).我在内容类型标题中使用了charset-utf-8(text/x-vcard; charset:utf-8).我使用了N; CHARSET = utf-8 :(和其他标签一样).
一切都无济于事.
有人有解决方案吗?感谢您分享您的见解.
使用的标题:
header("Content-type: text/x-vcard; charset=utf-8");
header("Content-Disposition: attachment; filename=".$this->filename.".vcf");
header("Pragma: public");
Run Code Online (Sandbox Code Playgroud)