adm-zip icon indicating copy to clipboard operation
adm-zip copied to clipboard

Can't show filename normal

Open huyinghuan opened this issue 11 years ago • 8 comments

when the file name is Chinese ,it can't display properly

huyinghuan avatar Dec 24 '13 17:12 huyinghuan

+1

ijse avatar Aug 07 '14 07:08 ijse

Same issue on my side with utf-8 chars like é, à or ê ....

any hint on how to fix this issue?

jbenguira avatar Oct 28 '15 09:10 jbenguira

@jocool No. I gave up.

huyinghuan avatar Oct 28 '15 09:10 huyinghuan

Hi there,

I face the same issue with chars like é, à, etc...

Is there a fix on the way or a workaround to this problem ?

vp-npetrini avatar Nov 24 '15 14:11 vp-npetrini

I've not found a solution yet ... no time to investigate ... if you find a solution please update the answer here ... i'll do the same

jbenguira avatar Nov 24 '15 14:11 jbenguira

Same problem here, always showing ����

payflix avatar Dec 16 '17 10:12 payflix

  • same problem

rojerv avatar Jan 30 '18 12:01 rojerv

should be done like this, take chinese encoding for example:

const AdmZip = require('adm-zip')
const iconv = require('iconv-lite')
const zip = new AdmZip('path/to/your/zip/file')

zip.getEntries().forEach(entry => {
    entry.entryName = iconv.decode(entry.rawEntryName, 'gbk')
    console.log(entry.entryName)
})

zip.extractAllTo('path/to/extract')

wangdahoo avatar Mar 03 '18 08:03 wangdahoo