How can php or js convert the transaction records csv files downloaded from Alipay into UTF8 codes?

this can see my other question: https://codeshelper.com/q/10.

.

the situation is that I want to download the transaction records in Alipay website in csv file format, and then import the data through my web application. But the table generated through datatables.net is shown in the following figure:

the downloaded csv file opens with notepad to show that it is ANSI, then saves the UTF8-encoded CSV file and then displays the Chinese language normally through the same datatable display. So I would like to ask if there is any good way to solve it under PHP or js.

Thank you.

Mar.10,2021

iconv ('GBK',' UTF-8//IGNORE', $content_of_csv);

see http://php.net/manual/zh/func.

Menu