unzip strings in javascript [closed]

本小妞迷上赌 提交于 2019-12-04 06:04:09

No need to unzip the KMZ file as Google Maps absolutely understands it. You can check it, simply search for the URL where your KMZ file is located in the Google Maps web interface and it will show its content on the map.

Here is a demo.

mr-euro

Perhaps ZipReader from Mozilla can be used for what you are after.

https://developer.mozilla.org/en/nsIZipReader

DotNetZip has a COM interface, that can be accessed from Javascript. It has a stream-to-stream unzip capability, but I have never tried using that from Javascript.
Also I have never tried using the library in any way from within IE.

kthoom implements unzip on a binary string: http://kthoom.googlecode.com/

I know this is an old question with an accepted answer, but just for the sake of interesting information, I'll post another answer. I put together a javascript-only library to read and extract zip files from any browser. It does not require Mozilla's ZipReader nor any ActiveX (aside from XMLHttpRequest).

You can see a working example here:
http://cheeso.members.winisp.net/Unzip-Example.htm

And you can download the source code from here:
http://cheeso.members.winisp.net/examples.aspx#js

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!