PapaParse icon indicating copy to clipboard operation
PapaParse copied to clipboard

Parse csv file with 'gbk' encoding error

Open GarasChan opened this issue 4 years ago • 2 comments

I parse a csv file that encoding is 'utf-8-bom' with encoding 'gbk', it return the same result with encoding 'utf-8'. current result: image expect result: image

GarasChan avatar Dec 29 '20 01:12 GarasChan

Hi @ChenGuanglin0924 ,

I do not understand your issue. Could you please clarify which configuration are you using to parse the file? What do yo mean with is 'utf-8-bom'? It starts with the utf-8-bom?

It will be also great if you can share the PapaParse version you are using.

pokoli avatar Dec 29 '20 07:12 pokoli

Steps to Trigger Behavior: 1、In window system, open a csv file that encoding is 'utf-8' and save as new encoding 'utf-8' with BOM. 2、Parse this file with encoding 'gbk', it return the same result with encoding 'utf-8', but the result is not the expect.

I do it with default configuration in the demo on the website.

GarasChan avatar Dec 29 '20 07:12 GarasChan